Using GET_FEATURES and FEATURES |
Layer Name | Shapefile Name | Layer ID |
Ocean | WORLD30 | 0 |
Countries | CNTRY94 | 1 |
States | STATES | 2 |
Provinces | PROVINCE | 3 |
Cities | CITIES | 4 |
Map configuration file used with the GET_FEATURES requests that follow: |
<?xml version="1.0" encoding="UTF-8"?> <ARCXML version="1.1"> <CONFIG> <ENVIRONMENT> <LOCALE country="US" language="en" variant="" /> <UIFONT color="0,0,0" name="Arial" size="12" style="regular" /> </ENVIRONMENT> <MAP dynamic="true" > <PROPERTIES> <ENVELOPE minx="-180" miny="-90" maxx="180" maxy="90" name="Initial_Extent" /> <MAPUNITS units="decimal_degrees" /> </PROPERTIES> <WORKSPACES> <SHAPEWORKSPACE name="shp_ws-0" directory="C:\ESRIDATA\WORLD" /> <SHAPEWORKSPACE name="shp_ws-2" directory="C:\ESRIDATA\USA" /> <SHAPEWORKSPACE name="shp_ws-3" directory="C:\ESRIDATA\CANADA" /> </WORKSPACES> <LAYER type="featureclass" name="Ocean" visible="true" id="0"> <DATASET name="WORLD30" type="polygon" workspace="shp_ws-0" /> <SIMPLERENDERER> <SIMPLEPOLYGONSYMBOL filltype="solid" fillcolor="0,153,255" /> </SIMPLERENDERER> </LAYER> <LAYER type="featureclass" name="Countries" visible="true" id="1"> <DATASET name="CNTRY94" type="polygon" workspace="shp_ws-0" /> <SIMPLERENDERER> <SIMPLEPOLYGONSYMBOL filltype="solid" fillcolor="255,255,153"/> </SIMPLERENDERER> </LAYER> <LAYER type="featureclass" name="States" visible="true" id="2"> <DATASET name="STATES" type="polygon" workspace="shp_ws-2" /> <SIMPLERENDERER> <SIMPLEPOLYGONSYMBOL filltype="solid" fillcolor="255,0,0" /> </SIMPLERENDERER> </LAYER> <LAYER type="featureclass" name="Provinces" visible="true" id="3"> <DATASET name="province" type="polygon" workspace="shp_ws-3" /> <SIMPLERENDERER> <SIMPLEPOLYGONSYMBOL filltype="solid" fillcolor="0,153,0" /> </SIMPLERENDERER> </LAYER> <LAYER type="featureclass" name="Cities" visible="true" id="4"> <DATASET name="CITIES" type="point" workspace="shp_ws-0" /> <SIMPLERENDERER> <SIMPLEMARKERSYMBOL color="102,0,102" width="8.0" /> </SIMPLERENDERER> </LAYER> </MAP> </CONFIG> </ARCXML> |
GET_FEATURES request with LAYER and SPATIALQUERY: |
<?xml version="1.0" encoding="UTF-8" ?> <ARCXML version="1.1"> <REQUEST> <GET_FEATURES featurelimit="25" beginrecord="0" outputmode="xml" geometry="false" envelope="true" globalenvelope="true"> <LAYER id="4" /> <SPATIALQUERY subfields="#ALL#" where="POPULATION > 10000000" > <SPATIALFILTER relation="area_intersection"> <ENVELOPE minx="-129" miny="16" maxx="-50" maxy="62"/> </SPATIALFILTER> </SPATIALQUERY> </GET_FEATURES> </REQUEST> </ARCXML> |
FEATURES response: |
<?xml version="1.0" encoding="UTF8"?> <ARCXML version="1.1"> <RESPONSE> <FEATURES> <FEATURE> <ENVELOPE minx="-99.127571105957" miny="19.4270458221436" maxx="-99.127571105957" maxy="19.4270458221436"/> <FIELDS NAME="Mexico City" POPULATION="14100000" #SHAPE#="[Geometry]" /> </FEATURE> <FEATURE> <ENVELOPE minx="-74.0999984741211" miny="40.75" maxx="-74.0999984741211" maxy="40.75"/> <FIELDS NAME="New York" POPULATION="16472000" #SHAPE#="[Geometry]" /> </FEATURE> <FEATURECOUNT count="2" hasmore="false" /> <ENVELOPE minx="-99.127571105957" miny="19.4270458221436" maxx="-74.0999984741211" maxy="40.75"/> </FEATURES> </RESPONSE> </ARCXML> |
Feature Services | Image Services | ArcMap Image Services | |
GET_FEATURES request uses: | Feature Streaming | ArcXML | ArcXML |
FEATURES response uses: | Feature Streaming | ArcXML | ArcXML |
GET_FEATURES request for attribute data sent to: | Feature Server | Query Server | ArcMap Server |
Request to draw map sent to: | Feature Server using GET_FEATURES | Image Server using GET_IMAGE | ArcMap Server using GET_IMAGE |
GET_FEATURES request when outputmode="xml": |
<?xml version="1.0" encoding="UTF-8"?> <ARCXML version="1.1"> <REQUEST> <GET_FEATURES outputmode="xml"> <LAYER id="2" /> <SPATIALQUERY subfields="state_name sub_region" where="STATE_NAME='Washington'" /> </GET_FEATURES> </REQUEST> </ARCXML> |
FEATURES response: |
<?xml version="1.0" encoding="UTF8"?> <ARCXML version="1.1"> <RESPONSE> <FEATURES> <FEATURE> <FIELDS STATE_NAME="Washington" SUB_REGION="Pacific" /> </FEATURE> <FEATURECOUNT count="1" hasmore="false" /> </FEATURES> </RESPONSE> </ARCXML> |
GET_FEATURES request when outputmode="newxml": |
<?xml version="1.0" encoding="UTF-8"?> <ARCXML version="1.1"> <REQUEST> <GET_FEATURES outputmode="newxml"> <LAYER id="2" /> <SPATIALQUERY subfields="state_name sub_region" where="STATE_NAME='Washington'" /> </GET_FEATURES> </REQUEST> </ARCXML> |
FEATURES response: |
<?xml version="1.0" encoding="UTF8"?> <ARCXML version="1.1"> <RESPONSE> <FEATURES> <FEATURE> <FIELDS> <FIELD name="STATE_NAME" value="Washington" /> <FIELD name="SUB_REGION" value="Pacific" /> </FIELDS> </FEATURE> <FEATURECOUNT count="1" hasmore="false" /> </FEATURES> </RESPONSE> </ARCXML> |
GET_FEATURES request when outputmode="xml", geometry="true", and compact="false": |
<?xml version="1.0" encoding="UTF-8"?> <ARCXML version="1.1"> <REQUEST> <GET_FEATURES outputmode="xml" geometry="true" compact="false"> <LAYER id="2" /> <SPATIALQUERY subfields="#SHAPE# state_name sub_region" where="STATE_NAME='Washington'" /> </GET_FEATURES> </REQUEST> </ARCXML> |
FEATURES response: |
<?xml version="1.0" encoding="UTF8"?> <ARCXML version="1.1"> <RESPONSE> <FEATURES> <FEATURE> <FIELDS STATE_NAME="Washington" SUB_REGION="Pacific" #SHAPE#="[Geometry]" /> <POLYGON> <RING> <POINT x="-122.400749" y="48.2253952" /> <POINT x="-122.461585" y="48.2285423" /> <POINT x="-122.453155" y="48.1286735" /> . . . . . <POINT x="-122.400749" y="48.2253952" /> </RING> </POLYGON> </FEATURE> <FEATURECOUNT count="1" hasmore="false" /> </FEATURES> </RESPONSE> </ARCXML> |
GET_FEATURES request when outputmode="xml", geometry="true", and compact="true": |
<?xml version="1.0" encoding="UTF8"?> <ARCXML version="1.1"> <REQUEST> <GET_FEATURES outputmode="xml" geometry="true" compact="true"> <LAYER id="2" /> <SPATIALQUERY subfields="#SHAPE# state_name sub_region" where="STATE_NAME='Washington'" /> </GET_FEATURES> </REQUEST> </ARCXML> |
FEATURES response: |
<?xml version="1.0" encoding="UTF8"?> <ARCXML version="1.1"> <RESPONSE> <FEATURES> <FEATURE> <FIELDS STATE_NAME="Washington" SUB_REGION="Pacific" #SHAPE#="[Geometry]" /> <POLYGON> <RING> <COORDS>-122.400749 48.2253952;-122.461585 48.2285423;-122.453155 48.1286735; . . . . .;-122.400749 48.2253952;-122.461585 48.2285423</COORDS> </RING> </POLYGON> </FEATURE> <FEATURECOUNT count="1" hasmore="false" /> </FEATURES> </RESPONSE> </ARCXML> |
GET_FEATURES request when featurelimit="7" and beginrecord="1": |
<?xml version="1.0" encoding="UTF8"?> <ARCXML version="1.1"> <REQUEST> <GET_FEATURES featurelimit="7" beginrecord="1" outputmode="xml" geometry="false"> <LAYER id="2" /> <SPATIALQUERY subfields="#SHAPE# state_name sub_region" where="SUB_REGION='Mtn'" /> </GET_FEATURES> </REQUEST> </ARCXML> |
FEATURES response: |
<?xml version="1.0" encoding="UTF8"?> <ARCXML version="1.1"> <RESPONSE> <FEATURES> <FEATURE> . . . First 6 Records Returned . . . </FEATURE> <FEATURE> <FIELDS STATE_NAME="Arizona" SUB_REGION="Mtn" #SHAPE#="[Geometry]" /> </FEATURE> <FEATURECOUNT count="7" hasmore="true" /> </FEATURES> </RESPONSE> </ARCXML> |
GET_FEATURES request when featurelimit="7" and beginrecord="8": |
<?xml version="1.0" encoding="UTF8"?> <ARCXML version="1.1"> <REQUEST> <GET_FEATURES featurelimit="7" beginrecord="8" outputmode="xml" geometry="false"> <LAYER id="2" /> <SPATIALQUERY subfields="#SHAPE# state_name sub_region" where="SUB_REGION='Mtn'" /> </GET_FEATURES> </REQUEST> </ARCXML> |
FEATURES response: |
<?xml version="1.0" encoding="UTF8"?> <ARCXML version="1.1"> <RESPONSE> <FEATURES> <FEATURE> <FIELDS STATE_NAME="New Mexico" SUB_REGION="Mtn" #SHAPE#="[Geometry]" /> </FEATURE> <FEATURECOUNT count="1" hasmore="false" /> </FEATURES> </RESPONSE> </ARCXML> |
GET_FEATURES request using skipfeatures: |
<?xml version="1.0" encoding="UTF-8"?> <ARCXML version="1.1"> <REQUEST> <GET_FEATURES skipfeatures="true" outputmode="newxml"> <LAYER id="4" /> <SPATIALQUERY subfields="#ALL#" where="POPULATION > 10000000" /> </GET_FEATURES> </REQUEST> </ARCXML> |
FEATURES response: |
<?xml version="1.0" encoding="UTF8"?> <ARCXML version="1.1"> <RESPONSE> <FEATURES> <FEATURECOUNT count="11" hasmore="false" /> </FEATURES> </RESPONSE> </ARCXML> |
GET_FEATURES request using skipfeatures and featurelimit: |
<?xml version="1.0" encoding="UTF-8"?> <ARCXML version="1.1"> <REQUEST> <GET_FEATURES skipfeatures="true" outputmode="newxml" featurelimit="5" beginrecord="1"> <LAYER id="4" /> <SPATIALQUERY subfields="#ALL#" where="POPULATION > 10000000" /> </GET_FEATURES> </REQUEST> </ARCXML> |
FEATURES response: |
<?xml version="1.0" encoding="UTF8"?> <ARCXML version="1.1"> <RESPONSE> <FEATURES> <FEATURECOUNT count="5" hasmore="true" /> </FEATURES> </RESPONSE> </ARCXML> |
GET_FEATURES request using skipfeatures and empty where clause: |
<?xml version="1.0" encoding="UTF-8"?> <ARCXML version="1.1"> <REQUEST> <GET_FEATURES skipfeatures="true" outputmode="newxml" > <LAYER id="4" /> <SPATIALQUERY subfields="#ALL#" where="" /> </GET_FEATURES> </REQUEST> </ARCXML> |
FEATURES response: |
<?xml version="1.0" encoding="UTF8"?> <ARCXML version="1.1"> <RESPONSE> <FEATURES> <FEATURECOUNT count="606" hasmore="false" /> </FEATURES> </RESPONSE> </ARCXML> |
GET_FEATURES request when attributes="true", envelope="true", and checkesc="true": |
<?xml version="1.0" encoding="UTF8"?> <ARCXML version="1.1"> <REQUEST> <GET_FEATURES outputmode="xml" geometry="false" attributes="true" envelope="true" checkesc="true"> <LAYER id="2" /> <SPATIALQUERY subfields="#SHAPE# state_name sub_region" where="STATE_NAME='Washington'" /> </GET_FEATURES> </REQUEST> </ARCXML> |
FEATURES response: |
<?xml version="1.0" encoding="UTF8"?> <ARCXML version="1.1"> <RESPONSE> <FEATURES> <FEATURE> <ENVELOPE minx="-124.731422" miny="45.5432510" maxx="-116.918151" maxy="49.0000038"/> <FIELDS STATE_NAME="Washington" SUB_REGION="P&NW" #SHAPE#="[Geometry]" /> </FEATURE> <FEATURECOUNT count="1" hasmore="false" /> </FEATURES> </RESPONSE> </ARCXML> |
GET_FEATURES request when attributes="false", envelope="true", and gloabalenvelope="true": |
<?xml version="1.0" encoding="UTF8"?> <ARCXML version="1.1"> <REQUEST> <GET_FEATURES outputmode="xml" geometry="false" attributes="false" envelope="true" globalenvelope="true"> <LAYER id="2" /> <SPATIALQUERY subfields="#SHAPE#" where="SUB_REGION='Pacific'" /> </GET_FEATURES> </REQUEST> </ARCXML> |
FEATURES response: |
<?xml version="1.0" encoding="UTF8"?> <ARCXML version="1.1"> <RESPONSE> <FEATURES> <FEATURE> <ENVELOPE minx="-124.731422424316" miny="45.5432510375977" maxx="-116.918151855469" maxy="49.0000038146973"/> </FEATURE> <FEATURE> <ENVELOPE minx="-124.558395385742" miny="41.9877891540527" maxx="-116.469444274902" maxy="46.2362594604492"/> </FEATURE> <FEATURE> <ENVELOPE minx="-124.391471862793" miny="32.5357246398926" maxx="-114.124450683594" maxy="42.0023460388184"/> </FEATURE> <FEATURE> <ENVELOPE minx="-160.245178222656" miny="18.9247817993164" maxx="-154.793869018555" maxy="22.2324924468994"/> </FEATURE> <FEATURE> <ENVELOPE minx="-178.215026855469" miny="51.5844345092773" maxx="-129.990539550781" maxy="71.4066467285156"/> </FEATURE> <FEATURECOUNT count="5" hasmore="false" /> <ENVELOPE minx="-178.215026855469" miny="18.9247817993164" maxx="-114.124450683594" maxy="71.4066467285156"/> </FEATURES> </RESPONSE> </ARCXML> |
Using FILTERCOORDSYS and FEATURECOORDSYS in a GET_FEATURES request: |
<?xml version="1.0" encoding="UTF-8" ?> <ARCXML version="1.1"> <REQUEST> <GET_FEATURES featurelimit="25" beginrecord="0" outputmode="xml" geometry="true" envelope="true" compact="true"> <LAYER id="4" /> <SPATIALQUERY subfields="#ALL#" where="POPULATION > 10000000" > <FILTERCOORDSYS id="54030" /> <FEATURECOORDSYS id="54030" /> <SPATIALFILTER relation="area_intersection"> <ENVELOPE minx="-11395772" miny="930558" maxx="-3878142" maxy="6419621"/> </SPATIALFILTER> </SPATIALQUERY> </GET_FEATURES> </REQUEST> </ARCXML> |
FEATURES response with FILTERCOORDSYS and FEATURECOORDSYS set to Robinson ("54030"): |
<?xml version="1.0" encoding="UTF8"?> <ARCXML version="1.1"> <RESPONSE> <FEATURES> <FEATURE> <ENVELOPE minx="-9197766.55659269" miny="2075483.92733491" maxx="-9197766.55659269" maxy="2075483.92733491"/> <FIELDS NAME="Mexico City" COUNTRY="Mexico" POPULATION="14100000" CAPITAL="Y" #SHAPE#="[Geometry]" #ID#="221" /> <MULTIPOINT> <COORDS>-9197766.55659269 2075483.92733491</COORDS> </MULTIPOINT> </FEATURE> <FEATURE> <ENVELOPE minx="-6419931.44911452" miny="4351163.61842219" maxx="-6419931.44911452" maxy="4351163.61842219"/> <FIELDS NAME="New York" COUNTRY="US" POPULATION="16472000" CAPITAL="N" #SHAPE#="[Geometry]" #ID#="549" /> <MULTIPOINT> <COORDS>-6419931.44911452 4351163.61842219</COORDS> </MULTIPOINT> </FEATURE> <FEATURECOUNT count="2" hasmore="false" /> </FEATURES> </RESPONSE> </ARCXML> |
Using FILTERCOORDSYS in Robinson ("54030") and FEATURECOORDSYS in geographic coordinates ("4326") in a GET_FEATURES request: |
<?xml version="1.0" encoding="UTF-8" ?> <ARCXML version="1.1"> <REQUEST> <GET_FEATURES featurelimit="25" beginrecord="0" outputmode="xml" geometry="true" envelope="true" compact="true"> <LAYER id="4" /> <SPATIALQUERY subfields="#ALL#" where="POPULATION > 10000000" > <FILTERCOORDSYS id="54030" /> <FEATURECOORDSYS id="4326" /> <SPATIALFILTER relation="area_intersection"> <ENVELOPE minx="-11395772" miny="930558" maxx="-3878142" maxy="6419621"/> </SPATIALFILTER> </SPATIALQUERY> </GET_FEATURES> </REQUEST> </ARCXML> |
FEATURES response with FILTERCOORDSYS set to Robinson (54030) and FEATURECOORDSYS set to geographic coordinates (4326): |
<?xml version="1.0" encoding="UTF8"?> <ARCXML version="1.1"> <RESPONSE> <FEATURES> <FEATURE> <ENVELOPE minx="-99.127571105957" miny="19.4270458221436" maxx="-99.127571105957" maxy="19.4270458221436"/> <FIELDS NAME="Mexico City" COUNTRY="Mexico" POPULATION="14100000" CAPITAL="Y" #SHAPE#="[Geometry]" #ID#="221" /> <MULTIPOINT> <COORDS>-99.127571105957 19.4270458221436</COORDS> </MULTIPOINT> </FEATURE> <FEATURE> <ENVELOPE minx="-74.0999984741211" miny="40.75" maxx="-74.0999984741211" maxy="40.75"/> <FIELDS NAME="New York" COUNTRY="US" POPULATION="16472000" CAPITAL="N" #SHAPE#="[Geometry]" #ID#="549" /> <MULTIPOINT> <COORDS>-74.0999984741211 40.75</COORDS> </MULTIPOINT> </FEATURE> <FEATURECOUNT count="2" hasmore="false" /> </FEATURES> </RESPONSE> </ARCXML> |