[Geoserver-users] GetFeatureInfo geoserver 1.7.2

Dear All,
I have to update some features in a layer but I have a problem. The datastore is ORACLE 10g.
I perform a GetFeatureInfo with BBOX filter and the result that this query returns differs from feature to feature.
For instance if my layer has the following schema:

<xsd:schema elementFormDefault=“qualified” targetNamespace=“http://idtcal.regione.calabria.it/idtcal”>
<xsd:import namespace=“http://www.opengis.net/gml” schemaLocation=“http://192.168.11.241:8280/geoserver/schemas/gml/3.1.1/base/gml.xsd”/>
<xsd:complexType name=“ESHOP_65_VERTICI_CALABRIAType”>
xsd:complexContent
<xsd:extension base=“gml:AbstractFeatureType”>
xsd:sequence
<xsd:element maxOccurs=“1” minOccurs=“0” name=“GMROTATION” nillable=“true” type=“xsd:double”/>
<xsd:element maxOccurs=“1” minOccurs=“0” name=“NORD” nillable=“true” type=“xsd:double”/>
<xsd:element maxOccurs=“1” minOccurs=“0” name=“EST” nillable=“true” type=“xsd:double”/>
<xsd:element maxOccurs=“1” minOccurs=“0” name=“ID” nillable=“true” type=“xsd:decimal”/>
<xsd:element maxOccurs=“1” minOccurs=“0” name=“GEOMETRY” nillable=“true” type=“gml:GeometryPropertyType”/>
<xsd:element maxOccurs=“1” minOccurs=“0” name=“PROV_DESCR” nillable=“true” type=“xsd:string”/>
<xsd:element maxOccurs=“1” minOccurs=“0” name=“COM_DESCR” nillable=“true” type=“xsd:string”/>
<xsd:element maxOccurs=“1” minOccurs=“0” name=“ID_COM” nillable=“true” type=“xsd:string”/>
<xsd:element maxOccurs=“1” minOccurs=“0” name=“ID_PROV” nillable=“true” type=“xsd:string”/>
<xsd:element maxOccurs=“1” minOccurs=“0” name=“DENOMINAZIONE” nillable=“true” type=“xsd:string”/>
<xsd:element maxOccurs=“1” minOccurs=“0” name=“PATH” nillable=“true” type=“xsd:string”/>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
<xsd:element name=“ESHOP_65_VERTICI_CALABRIA” substitutionGroup=“gml:_Feature” type=“idtcal:ESHOP_65_VERTICI_CALABRIAType”/>
</xsd:schema>

I would like that in my GetFeatureInfo response I will receive this schema always when a field is not valorized for a feature.

I.e. if the feature #2 has the field ID_PROV = null on the database I would receive the following:

<idtcal:ESHOP_65_VERTICI_CALABRIA gml:id=“ESHOP_65_VERTICI_CALABRIA.2”>
idtcal:GMROTATION8.00417575589457E-6</idtcal:GMROTATION>
idtcal:NORD4276187.306</idtcal:NORD>
idtcal:EST2619098.081</idtcal:EST>
idtcal:ID4</idtcal:ID>
idtcal:GEOMETRY…</idtcal:GEOMETRY>
idtcal:PROV_DESCRVIBO VALENTIA</idtcal:PROV_DESCR>
idtcal:COM_DESCRFRANCICA</idtcal:COM_DESCR>
idtcal:ID_COM102015</idtcal:ID_COM>
idtcal:ID_PROV</idtcal:ID_PROV>
idtcal:DENOMINAZIONE5074</idtcal:DENOMINAZIONE>
idtcal:PATH/mapbuilderWeb/pr5sit/MONOGRAFIE/</idtcal:PATH>
</idtcal:ESHOP_65_VERTICI_CALABRIA>

but I receive the following (without idtcal:ID_PROV</idtcal:ID_PROV>):

<idtcal:ESHOP_65_VERTICI_CALABRIA gml:id=“ESHOP_65_VERTICI_CALABRIA.2”>
idtcal:GMROTATION8.00417575589457E-6</idtcal:GMROTATION>
idtcal:NORD4276187.306</idtcal:NORD>
idtcal:EST2619098.081</idtcal:EST>
idtcal:ID4</idtcal:ID>
idtcal:GEOMETRY…</idtcal:GEOMETRY>
idtcal:PROV_DESCRVIBO VALENTIA</idtcal:PROV_DESCR>
idtcal:COM_DESCRFRANCICA</idtcal:COM_DESCR>
idtcal:ID_COM102015</idtcal:ID_COM>
idtcal:DENOMINAZIONE5074</idtcal:DENOMINAZIONE>
idtcal:PATH/mapbuilderWeb/pr5sit/MONOGRAFIE/</idtcal:PATH>
</idtcal:ESHOP_65_VERTICI_CALABRIA>

How can I modify the feature if I miss some fields? If I want to update the ID_PROV field how can I do?

Thanks,
Marianna

Hi Marianna,

Unfortunately this is something that is mandated by the WFS specification. It states that in the case of null values the element should not be output at all.

So if you want to include the feature you will have to update null fields so that they are an empty string.

-Justin

Marianna Borriello wrote:

Dear All,
I have to update some features in a layer but I have a problem. The datastore is ORACLE 10g.
I perform a GetFeatureInfo with BBOX filter and the result that this query returns differs from feature to feature.
For instance if my layer has the following schema:

<xsd:schema elementFormDefault="qualified" targetNamespace="http://idtcal.regione.calabria.it/idtcal&quot;&gt;
    <xsd:import namespace="http://www.opengis.net/gml&quot; schemaLocation="http://192.168.11.241:8280/geoserver/schemas/gml/3.1.1/base/gml.xsd&quot;/&gt;
    <xsd:complexType name="ESHOP_65_VERTICI_CALABRIAType">
        <xsd:complexContent>
            <xsd:extension base="gml:AbstractFeatureType">
                <xsd:sequence>
                    <xsd:element maxOccurs="1" minOccurs="0" name="GMROTATION" nillable="true" type="xsd:double"/>
                    <xsd:element maxOccurs="1" minOccurs="0" name="NORD" nillable="true" type="xsd:double"/>
                    <xsd:element maxOccurs="1" minOccurs="0" name="EST" nillable="true" type="xsd:double"/>
                    <xsd:element maxOccurs="1" minOccurs="0" name="ID" nillable="true" type="xsd:decimal"/>
                    <xsd:element maxOccurs="1" minOccurs="0" name="GEOMETRY" nillable="true" type="gml:GeometryPropertyType"/>
                    <xsd:element maxOccurs="1" minOccurs="0" name="PROV_DESCR" nillable="true" type="xsd:string"/>
                    <xsd:element maxOccurs="1" minOccurs="0" name="COM_DESCR" nillable="true" type="xsd:string"/>
                    <xsd:element maxOccurs="1" minOccurs="0" name="ID_COM" nillable="true" type="xsd:string"/>
                    <xsd:element maxOccurs="1" minOccurs="0" name="ID_PROV" nillable="true" type="xsd:string"/>
                    <xsd:element maxOccurs="1" minOccurs="0" name="DENOMINAZIONE" nillable="true" type="xsd:string"/>
                    <xsd:element maxOccurs="1" minOccurs="0" name="PATH" nillable="true" type="xsd:string"/>
                </xsd:sequence>
            </xsd:extension>
        </xsd:complexContent>
    </xsd:complexType>
    <xsd:element name="ESHOP_65_VERTICI_CALABRIA" substitutionGroup="gml:_Feature" type="idtcal:ESHOP_65_VERTICI_CALABRIAType"/>
</xsd:schema>*
*
*_I would like that in my GetFeatureInfo response I will receive this schema always when a field is not valorized for a feature._*

I.e. if the feature #2 has the field ID_PROV = null on the database I would receive the following:

<idtcal:ESHOP_65_VERTICI_CALABRIA gml:id="ESHOP_65_VERTICI_CALABRIA.2">
    <idtcal:GMROTATION>8.00417575589457E-6</idtcal:GMROTATION>
    <idtcal:NORD>4276187.306</idtcal:NORD>
    <idtcal:EST>2619098.081</idtcal:EST>
    <idtcal:ID>4</idtcal:ID>
    <idtcal:GEOMETRY>...</idtcal:GEOMETRY>
    <idtcal:PROV_DESCR>VIBO VALENTIA</idtcal:PROV_DESCR>
    <idtcal:COM_DESCR>FRANCICA</idtcal:COM_DESCR>
    <idtcal:ID_COM>102015</idtcal:ID_COM>
   * <idtcal:ID_PROV></idtcal:ID_PROV>*
    <idtcal:DENOMINAZIONE>5074</idtcal:DENOMINAZIONE>
    <idtcal:PATH>/mapbuilderWeb/pr5sit/MONOGRAFIE/</idtcal:PATH>
</idtcal:ESHOP_65_VERTICI_CALABRIA>

but I receive the following (without * *<idtcal:ID_PROV></idtcal:ID_PROV>):

<idtcal:ESHOP_65_VERTICI_CALABRIA gml:id="ESHOP_65_VERTICI_CALABRIA.2">
    <idtcal:GMROTATION>8.00417575589457E-6</idtcal:GMROTATION>
    <idtcal:NORD>4276187.306</idtcal:NORD>
    <idtcal:EST>2619098.081</idtcal:EST>
    <idtcal:ID>4</idtcal:ID>
    <idtcal:GEOMETRY>...</idtcal:GEOMETRY>
    <idtcal:PROV_DESCR>VIBO VALENTIA</idtcal:PROV_DESCR>
    <idtcal:COM_DESCR>FRANCICA</idtcal:COM_DESCR>
    <idtcal:ID_COM>102015</idtcal:ID_COM>
    <idtcal:DENOMINAZIONE>5074</idtcal:DENOMINAZIONE>
    <idtcal:PATH>/mapbuilderWeb/pr5sit/MONOGRAFIE/</idtcal:PATH>
</idtcal:ESHOP_65_VERTICI_CALABRIA>

How can I modify the feature if I miss some fields? If I want to update the ID_PROV field how can I do?

Thanks,
Marianna

------------------------------------------------------------------------------
Apps built with the Adobe(R) Flex(R) framework and Flex Builder(TM) are
powering Web 2.0 with engaging, cross-platform capabilities. Quickly and
easily build your RIAs with Flex Builder, the Eclipse(TM)based development
software that enables intelligent coding and step-through debugging.
Download the free 60 day trial. http://p.sf.net/sfu/www-adobe-com

------------------------------------------------------------------------

_______________________________________________
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users

--
Justin Deoliveira
OpenGeo - http://opengeo.org
Enterprise support for open source geospatial.