Mast head image

Ecological Site by Area Symbol

This script retrieves the ecological site ID and name by area symbol.


Text highlighted in yellow in the example script can be changed for a particular area, or you can use wildcards to get an entire State. Examples can be found on the Tips page.

Tips Page

Copy the example script below and paste it into the query page on the Soil Data Access site.

Soil Data Access Query Page

Example Script

SELECT l.areasymbol AS Area_symbol, l.areaname AS Area_name, musym AS Map_unit_symbol, mu.mukey AS MUKEY,

compname AS Component,comppct_r AS Component_percentage, coe.ecoclassid AS Eco_class_ID, coe.ecoclassname AS Ecosite_class_name

FROM sacatalog AS sac

INNER JOIN legend AS l ON l.areasymbol = sac.areasymbol AND l.areatypename = 'Non-MLRA Soil Survey Area'

INNER JOIN mapunit AS mu ON mu.lkey = l.lkey

INNER JOIN component AS c ON c.mukey = mu.mukey

LEFT OUTER JOIN coecoclass AS coe ON c.cokey = coe.cokey

WHERE majcompflag = 'Yes' AND sac.areasymbol LIKE 'WA001'

ORDER BY l.areasymbol, musym, compname, comppct_r DESC

Example Table Output

Description of tables and columns can be found on this link: Table and Column Descriptions

Area_symbol Area_name Map_unit_symbol MUKEY Component Component_percentage Eco_class_ID Ecosite_class_name
WA001 Adams County, Washington ABB 68122 Anders 100 R008XY103WA COOL LOAMY 10-16 PZ
WA001 Adams County, Washington ALC 68126 Kuhl 30 R008XY202WA STONY 10-16 PZ
WA001 Adams County, Washington UmA 68276 Umapine 100 R007XY401WA ALKALI BOTTOM 6-10 PZ



Helping People Help the Land

USDA is an equal opportunity provider, employer, and lender.