[Mapserver-users] Finding Extent

Swaminathan, Gayathri gayathri@ou.edu
Sun, 9 May 2004 15:29:29 -0500


Hi:

I am having a problem with figuring the best possible way to find extent
of my results for my mapping application..

My present query is:

"select xmin(extent(the_geom)),
ymin(extent(the_geom)),xmax(extent(the_geom)),ymax(extent(the_geom))
from nc where parcels_id in (<list of parcels>);"

But this ends up being a index scan on the parcels_id...and costs of
this query are directly tied to the number of parcels in my results.

I have indexes on the_geom, oid and parcels_id

I have done a vacuum analyze on this database.

But nothing seems to help the runtime of this query.

Version of Postgresql is 7.2.1
Version of Postgis is 0.7.5

What am I doing wrong? Is there a better way to find extents for
returned results.

Thanks
Gayathri





_______________________________________________
Mapserver-users mailing list
Mapserver-users@lists.gis.umn.edu
http://lists.gis.umn.edu/mailman/listinfo/mapserver-users