[postgis-users] slow extent queries?

Chetan Tiwari chetan.tiwari at gmail.com
Sat Jun 16 17:06:06 PDT 2007


Hi All

I had a quick question about a relatively simple problem. I have 2
point-based datasets (table1 and table2). I'd like to find out which dataset
covers a larger geographic area. I guess there can be several ways of trying
to figure that out. What I'm using is a query like

select extent(t1.the_geom) ~ extent(t2.the_geom) from myschema.table1 t1,
myschema.table2 t2;

Table 1 contains about 5500 points and table 2 around 8000. The query takes
about a minute to execute (with and without indexes on the_geom) and I was
wondering if there was something that I was doing wrong or if there was a
more efficient way of accomplishing this task?

Thanks much,

Chetan
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/postgis-users/attachments/20070616/ab904675/attachment.html>


More information about the postgis-users mailing list