[postgis-users] Polygon grid to multiband raster?

David Quinn daithiquinn at gmail.com
Sat Mar 17 14:46:28 PDT 2012


Hi List,

Is it possible to convert a polygon grid into a multiband raster in PostGIS
2.0?

For example, I saw on an earlier question that a multiband raster can be
generated using the following code:

CREATE newtable AS
SELECT ST_AddBand(ST_Band(table1.rast, 1), ST_Band(table2.rast, 1)) rast
FROM table1, table2
WHERE table1.rid = table2.rid

Is it possible to do something like the following?

CREATE newtable AS
SELECT ST_AddBand( "rasterize (t.geom, col1)", "rasterize (t..geom, col2)"
)  rast
FROM table1 as t

where "rasterize (t.geom, col1)" is my pseudocode description of how I want
to convert the polygon grid into a raster, using a column name.

- David
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/postgis-users/attachments/20120317/dc65a48c/attachment.html>


More information about the postgis-users mailing list