[postgis-users] ST_Intersects(geom, geom) Memory issue

Sandro Santilli strk at keybit.net
Thu Feb 9 07:32:15 PST 2012


On Thu, Feb 09, 2012 at 03:59:08PM +0100, Andreas Forø Tollefsen wrote:
> Hi Sandro,
> 
> Rewrote the script to:
> INSERT INTO geoepr_cell SELECT a.gid, a.gridyear,  g.cowgroup, g.type,
> SUM(ST_Area(ST_Intersection(p.cell, g.the_geom)))
> FROM priogridall a, priogrid p, geoepreth2valid g
> WHERE a.gid = p.gid AND a.gridyear = 1946 AND a.gwcode = g.cowcode AND
> ST_Intersects(p.cell, g.the_geom) AND g.startyear <= 1946 AND
> g.endyear >= 1946
> AND ST_Dimension(p.cell) != 0 AND ST_Dimension(g.the_geom) != 0
> GROUP BY a.gid, a.gridyear, g.cowgroup, g.type ORDER BY gid, gridyear ;
> 
> Same problem.

Right, I came to the same conclusion: its' the prepared geometry code
having memory issues, not the PostGIS cached PIP code. It looks like
every new object cached grows the total memory. 
Let's continue this on trac:
http://trac.osgeo.org/postgis/ticket/547

Thanks again.

--strk;

  ,------o-. 
  |   __/  |    Delivering high quality PostGIS 2.0 !
  |  / 2.0 |    http://strk.keybit.net
  `-o------'




More information about the postgis-users mailing list