gvSIG bugs #521

WFS: underscored attributes bug

Added by Manuel Madrid about 12 years ago. Updated over 10 years ago.

Status:New% Done:

0%

Priority:Normal
Assignee:Francisco Puga
Category:-
Target version:-
Severity: Add-on name:Unknown
gvSIG version:1.12.0 Add-on version:
gvSIG build:1417 Add-on build:
Operative System: Add-on resolve version:
Keywords: Add-on resolve build:
Has patch:No

Description

Migrated from https://joinup.ec.europa.eu/software/gvsig-desktop/issue/wfs-underscored-attributes-bug

This bug appears as fixed but the problem still happens in gvSIG 1.12 BN1406. Tested with this server:

http://wms.pcn.minambiente.it/cgi-bin/mapserv.exe?map=/ms_ogc/wfs/Autorita_bacino.map&request=getcapabilities&service=wfs&version=1.0.0

Original issue description:

If you add a WFS layer containing unederscored attributes to your vista, make it visible and you go to the Filer tab of the WFS attributes panel (reachable via the menu that appears right-clicking on the selected layer), you can see that underscored attributes are displayed correctly but when you click on one of them to see the known values, they aren't loaded. Oppositely, if you click on non-underscored attributes you'll see all known values. It is a problem that occurs when creating theSelectableDataSource associated to the WFS layer. In fact, when you read the field names of the layer you will see that underscored attributes contain white spaces. Use the following lines for example: SelectableDataSource sds = wfsLayer.getRecordset(); ReadableVectorial rv = wfsLayer.getSource(); // Desde el modelo se debería acceder a los campos y sus valores cargados for (int i = 0; i < sds.getFieldCount(); i++) { String fieldName = sds.getFieldName(i); ..... } The problem has also been reported twice: - http://osgeo-org.1803224.n2.nabble.com/WFS-layer-attributes-bug-td493565... - http://listserv.gva.es/pipermail/gvsig_internacional/2010-June/005484.html - http://listserv.gva.es/pipermail/gvsig_internacional/2010-June/005485.html - http://listserv.gva.es/pipermail/gvsig_internacional/2010-June/005487.html - http://listserv.gva.es/pipermail/gvsig_internacional/2010-June/005488.html

History

#1 Updated by Mario Carrera about 12 years ago

Other server that can be tested is:

- WFS Server: http://www.idee.es/IDEE-WFS/ogcwebservice
- Layer: Distribucion_25000

It also contains fields with "_" in their names.

#2 Updated by Jorge Piera about 12 years ago

Fixed r38193

#3 Updated by Francisco Puga almost 12 years ago

Thanks for the work Jorge.

Remember that if in the commit message you write something like

"WFS: underscored attributes bug fixes #521"

An automatic link is created by redmine between the commit and the bug. So you don't have to make a comment.

In redmine there are some "reserved word" like "fixes #bugNumber" that allow do this kind of things

#4 Updated by Francisco Puga almost 12 years ago

  • Status changed from New to Fixed
  • Target version changed from 1.12.0-final to 1.12.0-rc1

#5 Updated by Mario Carrera over 11 years ago

  • Status changed from Fixed to New
  • Target version changed from 1.12.0-rc1 to 1.12.0-final
  • gvSIG build changed from 1406 to 1417

#6 Updated by Antonio Falciano over 11 years ago

It seems that filter expressions with underscored field doesn't work properly. For instance, if we connect to the above mentioned server:
http://wms.pcn.minambiente.it/cgi-bin/mapserv.exe?map=/ms_ogc/wfs/Autorita_bacino.map&request=getcapabilities&service=wfs&version=1.0.0 and then try to apply a filter expression like "cod_adb" = '05' a java.lang.NullPointerException occurs and the resulting WFS layer is empty.

#7 Updated by Manuel Madrid over 11 years ago

  • Target version deleted (1.12.0-final)

#8 Updated by Álvaro Anguix over 10 years ago

  • Project changed from Application: gvSIG desktop to | gvSIG desktop 1
  • Category deleted (WFS)

Also available in: Atom PDF