[postgis-users] question on gist performance

Frank Koormann frank.koormann at intevation.de
Fri Sep 7 01:43:29 PDT 2007


Stefan,

* Stefan Zweig <stefanzweig1881 at web.de> [070907 10:07]:
> thanks for your quick reply. i have tried your advice and rebuilded
> all my gist indexes on the table (via drop index, create index) and
> run a vacuum full afterwards. but that did not change the fact, that
> the query on the_geom is much slower than the same one on the_geom_1.
> 
[...]
> 
>   '...WHERE the_geom && expr;' takes about 250ms,
>   '...WHERE the_geom_envelope && expr;' takes about 20ms.
> 
> ANALYZE says that GIST is used. As far as I know, the GIST makes use
> only of the bounding boxes of Geometry objects, which are equal for
> each object. How does it come that the query time using the_geom is more than
> *ten times slower* than the query time using the_geom_envelope?"

It would help if you post the explain analyse output.

Regards,

        Frank

-- 
Frank Koormann    |   ++49-541-335 08 30    |   http://www.intevation.net/
Intevation GmbH, Osnabrück, DE | Commercial Register Osnabrück, HR B 18998
Managing Directors: Frank Koormann, Bernhard Reiter, Dr. Jan-Oliver Wagner
PostGIS Support (http://www.intevation.net/geospatial/postgis-support.en.html)



More information about the postgis-users mailing list