Hi guys,
 
I have a postgis datastore in GeoServer 1.3.0-RC4.SP1.
 
Trying to send the following request:
 

<?xml version="1.0" encoding="iso-8859-1"?>

<GetFeature outputFormat="GML2" xmlns:gml="http://www.opengis.net/gml">
   <Query typeName="NURC:Main">
      <PropertyName>/Main/Source</PropertyName>
      <PropertyName>/Main/Year</PropertyName>
      <Filter>
         <And>
            <FeatureId fid="234"/>
            <BBOX>
               <PropertyName>/Main/the_geom</PropertyName>
               <gml:Box>
                  <gml:coord>
                     <gml:X>1</gml:X>
                     <gml:Y>40</gml:Y>
                  </gml:coord>
                  <gml:coord>
                     <gml:X>12</gml:X>
                     <gml:Y>56</gml:Y>
                  </gml:coord>
               </gml:Box>
            </BBOX>
            <PropertyIsEqualTo>
               <PropertyName>/Main/Year</PropertyName>
               <Literal>1988</Literal>
            </PropertyIsEqualTo>
         </And>
      </Filter>
   </Query>
</GetFeature>

 

GeoServer produces the following Exception:

org.geotools.data.DataSourceException: Error Performing SQL query: SELECT "ID", "Source", "Year" FROM "Main" WHERE ((ID = '234') AND "the_geom" && GeometryFromText('POLYGON ((1 40, 1 56, 12 56, 12 40, 1 40))', -1) AND "Year" = 1988)
....
....
....
Caused by: org.postgresql.util.PSQLException: ERROR: column "id" does not exist

Infact the SQL string is wrong, it should be:

... FROM "Main" WHERE (("ID" = '234') AND ...

instead of

... FROM "Main" WHERE ((ID = '234') AND ...

 

Does anyone knows the cuse?

 

Thanks,

                                   Alessio.

Reply via email to