Posted By

wildpeaks on 10/15/10


Postgresql postgis geospatial

Versions (?)

PostGIS: Bounding box of a MultiPolygon column

 / Published in: SQL

Important: this snipplet has moved to Github.

  1. -- If `polygons` is a column containing multipolygons, this returns one row per polygon.
  3. SELECT id AS id, ST_Box2D((ST_Dump(polygons)).geom) AS bbox FROM mytable WHERE polygons IS NOT NULL;

Report this snippet  

You need to login to post a comment.