[postgis-users] raster table extent

Pierre Racine Pierre.Racine at sbf.ulaval.ca
Wed Jun 15 06:51:06 PDT 2011


If you imported all of your rasters with one raster2pgsql command the "extent" column in the "raster_column" table should correspond to the global extent.

If you imported with many commands, added or deleted tiles afterward, "extent" is not up to date.

You can play with the ST_Extent aggregate.

SELECT ST_Extent(rast)
FROM your table

That would be the preferred way to get an uptodate extent. If it's slow, create an index on your raster column.

Pierre

> -----Original Message-----
> From: postgis-users-bounces at postgis.refractions.net [mailto:postgis-users-
> bounces at postgis.refractions.net] On Behalf Of Stephen Crawford
> Sent: Tuesday, June 14, 2011 7:04 PM
> To: PostGIS Users Discussion
> Subject: [postgis-users] raster table extent
> 
> Is there a function that can provide the extent for an entire raster table?  I see
> there is BOX2D for each raster in a table, but how about the entire table?
> Basically I think I loaded my raster in a way that the extent isn't where it should
> be, but I'm having trouble proving it.
> 
> Thanks,
> Steve
> 
> 
> _______________________________________________
> 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