Python API - Enrich Layer Failing

782
3
07-23-2019 10:53 AM
by Anonymous User
Not applicable

I'm trying to enrich a layer with Age data, but it keeps failing with it stating

{"messageCode": "AO_900009", "message": "Unable to get the GeoEnrichment layer Feature Count."}

or it states 

{"messageCode": "AO_100270", "message": "The size and number of the variables that you selected exceeds the maximum row size for feature service layer. Please reduce the number of selected variables."}

I have tried so many different things, but it keeps throwing this error.

Can anyone shed some light on whats going on?

Here is the code with 'demo_layer' being a feature layer.

0 Kudos
3 Replies
LanceCole
MVP Regular Contributor

Nikholai O'Hara‌, 

Should the distance parameter in your code be a string or float?  Try distance=5

0 Kudos
by Anonymous User
Not applicable

Thanks for the spot check, however, I still get the same error message.

{"messageCode": "AO_100270", "message": "The size and number of the variables that you selected exceeds the maximum row size for feature service layer. Please reduce the number of selected variables."}
0 Kudos
LanceCole
MVP Regular Contributor

Nikholai‌, 

How many items could this function be attempting to return from your feature service?  Is it exceeding the maxRecordCount value for the service?  This is typically a default of 1000 features.  Take a look at How To: Update the maximum record count for feature services in ArcGIS Online.  You can also perform a select on the feature to limit the possible number of returns to see if that will run.

0 Kudos