You can use the Overlap-function to retrieve the common area between the buffer 
and the polygons:

Select POLGONID, Round(CartesianArea(Overlap(BUFFERTABLE.OBJ, 
POLYGONTABLE.OBJ), "sq m"), 0.01) "Area_kvm"
        From BUFFERTABLE, POLYGONTABLE
        Where BUFFERTABLE.OBJ Intersects POLYGONTABLE.OBJ

Where:
- POLYGONID is some column in the tables with polygons that you can use to 
identify the polygons
- BUFFERTABLE is the name of the table with the buffer
- POLYGONTABLE is the name of the table with the polygons
- CartesianArea(..., "sq m") is the unit used for calculating the areas, you 
could also use "sq mi", "sq km", etc. You could also use SpericalArea if you 
prefer the Sperical area.
- "Area_kvm" is a alias for the column holding the overlapping area
- Round(..., 0.01) means that the area will be rounded to two decimals. You can 
add more decimals by adding zeros before 1 (0.0001)
- Overlap() returns the common area of the two objects

HTH,

Peter Horsb�ll M�ller
GIS Developer
Geographical Information & IT
 
COWI A/S
Odensevej 95
DK-5260 Odense S.
Denmark
 
Tel     +45 6311 4900
Direct  +45 6311 4908
Mob     +45 5156 1045
Fax     +45 6311 4949
E-mail  [EMAIL PROTECTED]
http://www.cowi.dk/gis


-----Original Message-----
From: Sarah Chisholm [mailto:[EMAIL PROTECTED] 
Sent: Monday, January 24, 2005 4:39 PM
To: [email protected]
Subject: MI-L Please help me with SQL select!


Hi all,
 
I'm very new to GIS and have a simple question about a SQL select query. I've 
created a buffer zone around a line and am trying to figure out the area of the 
parts of the polygons that are contained by this buffer. 
 
I can get the table to tell me the whole area of each polygon that touches the 
buffer (by using the Condition "bufferline.obj contains forest.obj" because 
'area' is a column in the 'forest' table), but I'd like to know the area of 
only the small section of the polygon that is contained by the buffer. Can 
someone tell me how I should fit 'area' into this query?
 
Thanks,
Sarah
 
 

Reply via email to