From c08f76f13b51c71e22b2485f2f4e8c94445f8392 Mon Sep 17 00:00:00 2001 From: Regina Obe Date: Mon, 21 Jul 2008 16:20:28 +0000 Subject: [PATCH] Remove ST_Area2D and replace with ST_Area - move to new section and provide example git-svn-id: http://svn.osgeo.org/postgis/trunk@2873 b70326c6-7e19-0410-871a-916f4a2858ee --- doc/reference.xml | 23 +-------------- doc/reference_new.xml | 66 ++++++++++++++++++++++++++++++++++++++++++- 2 files changed, 66 insertions(+), 23 deletions(-) diff --git a/doc/reference.xml b/doc/reference.xml index 70350f400..0eaf061af 100644 --- a/doc/reference.xml +++ b/doc/reference.xml @@ -1254,17 +1254,7 @@ GROUP BY gid, field1,field2; Measurement Functions - - - - ST_area2d(geometry) - - - Returns the area of the geometry if it is a polygon or - multi-polygon. - - - + ST_Distance_Sphere(point, point) @@ -2393,17 +2383,6 @@ WHERE n*100.00/length < 1; - - ST_Area - - - Return the area measurement of an ST_Surface or - ST_MultiSurface value. - - SQL-MM 3: 8.1.2, 9.5.3 - - - ST_AsBinary diff --git a/doc/reference_new.xml b/doc/reference_new.xml index aeb8772b0..e2a2d9cff 100644 --- a/doc/reference_new.xml +++ b/doc/reference_new.xml @@ -1106,7 +1106,71 @@ LINESTRING(1 2,1 10) | LINESTRING(1 10,1 2) - Spatial Relationships and Measurements + Spatial Relationships and Measurements + + + ST_Area + + Returns the area of the geometry if it is a polygon or + multi-polygon. + + + + + float ST_Area + geometry g1 + + + + + Description + + Returns the area of the geometry if it is a polygon or + multi-polygon. Return the area measurement of an ST_Surface or + ST_MultiSurface value. Area is in the units of the spatial reference system. + + + + + + This method implements the OpenGIS Simple Features + Implementation Specification for SQL. + + + + + + This method implements the SQL/MM specification: + SQL-MM 3: 8.1.2, 9.5.3 + + + + Examples + Return area in square feet for a plot of Massachusetts land. Note this is in square feet because 2249 is + Mass State Plane Feet + +SELECT ST_Area(ST_GeomFromText('POLYGON((743238 2967416,743238 2967450, + 743265 2967450,743265.625 2967416,743238 2967416))',2249)); +st_area +--------- + 928.625 +(1 row) + +--this returns in square meters +SELECT ST_Area(ST_Transform(ST_GeomFromText('POLYGON((743238 2967416,743238 2967450, + 743265 2967450,743265.625 2967416,743238 2967416))',2249), 26986)); +st_area +------------------ + 86.2724306061864 + + + + See Also + , , + + + -- 2.50.0