Hi.

I have some problems with GeoServer (2.5.2) and PostGIS (2.1.1). When I make a 
WFS request to a view on my database, I get a SELECT query like this:

SELECT "id",encode(ST_AsEWKB("geometry"),'base64') as "geometry" FROM 
"public"."my_table" WHERE  "geometry" && ST_GeomFromText('POLYGON 
((891837.6082013508 6147533.812230958, 891837.6082013508 6148331.277858112, 
893164.795314311 6148331.277858112, 893164.795314311 6147533.812230958, 
891837.6082013508 6147533.812230958))', ST_SRID("geometry")) LIMIT 1000000

I have an INDEX on the geometry column but the above query won't use it because 
of the ST_SRID("geometry") part (by replacing it with the declared EPSG code 
PostGIS uses the index).

I have declared an SRS but Geoserver hasn't been able to define a Native SRS 
(the field is empty and got '...' right next to it). Since I have declared an 
SRS I would expect it to be used directly in the query?

Can you give me a hint or two on where to look or what to change?

Regards, Casper


------------------------------------------------------------------------------
Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server
from Actuate! Instantly Supercharge Your Business Reports and Dashboards
with Interactivity, Sharing, Native Excel Exports, App Integration & more
Get technology previously reserved for billion-dollar corporations, FREE
http://pubads.g.doubleclick.net/gampad/clk?id=164703151&iu=/4140/ostg.clktrk
_______________________________________________
Geoserver-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geoserver-users

Reply via email to