[postgis-users] Web docs mistake?

Darryl Watson dwatson at roof-express.com
Wed May 24 09:24:07 PDT 2006


Hi-

The documentation in question:

http://postgis.refractions.net/docs/ch06.html#id2920638

The Envelope(geometry) docs say that this function returns a bounding 
box ((MINX, MINY), (MAXX, MINY), (MAXX, MAXY), (MINX, MAXY), (MINX, MINY)).

Here is an example query against geometries with SRID 4326:

select astext(envelope(geomunion(geom))) from county_bounds where 
spc83='0502';

What I get back:

"POLYGON((-109.060256958008 38.1468849182129,-109.060256958008 
40.0915412902832,-102.045066833496 40.0915412902832,-102.045066833496 
38.1468849182129,-109.060256958008 38.1468849182129))"

I submit that the docs should be: bounding box ((MINX MINY, MINX MAXY, 
MAXX MAXY, MAXX MINY, MINX MINY)).

Unless, this changes depending on what part of the world you're in?

My PostGIS version info:

"POSTGIS="1.0.3" GEOS="2.1.3" PROJ="Rel. 4.4.9, 29 Oct 2004" USE_STATS 
DBPROC="0.3.0" RELPROC="0.3.0""

By the way, thanks Refractions.net and other contributors for a 
wonderful GIS tool.  A year ago this month, I made a risky decision to 
avoid ESRI and develop our own GIS toolset with PostGIS, and I have not 
regretted it at all.  :-)



More information about the postgis-users mailing list