[postgis-users] Why does this take almost 3 hours?

dblasby at openplans.org dblasby at openplans.org
Tue Aug 30 10:38:34 PDT 2005


"intersects()" is very computationally expensive.  You might want to try
"distance() <=0" which can often short-circuit computation.

 SELECT a.catalogid, b.cii_region, a.the_geom
   FROM new_snaps a, nga_reg b
  WHERE a.the_geom && b.the_geom AND distance(a.the_geom,
b.the_geom)<=0;

dave



----------------------------------------------------------
This mail sent through IMP: https://webmail.limegroup.com/



More information about the postgis-users mailing list