[postgis-users] How best to build a regular grid from points
Randall, Eric
ERandall at eriecountygov.org
Sun Oct 17 16:02:01 PDT 2010
Hi Brent,
I use something like this, should be adaptable to your use (but might not be the best way).
this makes a 10000 foot sided cell, and translates it 10x and 10y.
Eric
select st_translate(geom, 0 ,yseries) as geom from
(select generate_series(0,90000, 10000) as yseries,st_translate(geom, xseries ,0) as geom from
(select generate_series(0, 90000, 10000) as xseries, geom from
(select st_envelope(st_makeline(st_makepoint(1380000,630000),st_makepoint(1390000,640000))) as geom) as t1) as t2) as t3
-----Original Message-----
From: postgis-users-bounces at postgis.refractions.net
[mailto:postgis-users-bounces at postgis.refractions.net]On Behalf Of
pcreso at pcreso.com
Sent: Sunday, October 17, 2010 1:39 PM
To: postgis-users at postgis.refractions.net
Subject: [postgis-users] How best to build a regular grid from points
Hi,
I have a set of 155,000,000 points on a regular grid. I need to convert these to a set of square polygons covering the area represented by the points.
Can anyone suggest how this could be done in Postgis?
Thanks,
Brent Wood
_______________________________________________
postgis-users mailing list
postgis-users at postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users
More information about the postgis-users
mailing list