[GIS] Why is sometimes geometryType not returned in JSON from ArcGIS Server layer REST API

arcgis-10.0arcgis-serverdevelopmentrest

Does someone know why the geometryType not always get returned from ArcGIS Server layers?

According to the API documentation Layer / Table the geometryType is returned on layers:

//properties specific to layers only 
"geometryType" : "<geometryType>",

But on some layers the resulting JSON looks like this:

"geometryType" : "",

The layers I'm testing on is our own and as far as I can see they are set up in the same manner,:capabilities with mapping and web access enabled. Dynamic layers. Some layers return the correct geometry type and some don't.

Update: Clearing the cache See rest admin does not help.

Best Answer

Is the SHAPE field visible in your MXD? If you obscure this field it is difficult to determine the nature of the geometry, so it may not display the geometryType.

We've had troubles with geometry operations with ArcObjects when the user hid the OBJECTID and SHAPE fields in ArcMap.

Related Question