I have Published a Shapefile as a Hosted Layer on ArcGIS Online.

I now want to run some Queries on it, which will include a Group by query, which can supposedly be done by using the outStatistics & groupByFieldsForStatistics parameters.

The Help for the outStatistics says that

outStatistics is supported on only those layers/tables that indicate supportsStatistics is true.

How Do I enable this supportsStatistics on my hosted feature service?

1 Answer 1


As the Documentation for Layer/Table States:

supportsStatistics would return false in the following scenarios:

  • The layer / table resides in a workspace other than an enterprise or file geodatabase.
  • The layer / table has more than one join defined on it.
  • The layer / table is joined with another layer / table from a different workspace.
  • The layer / table has an "outer" join and where the workspace is a pre-10.1 Geodatabase and application server connection is used.

Since the Source of this hosted layer is a shapefile, it does not support queryies with Statitistics.

The Solution is to Create a File Geodatabase with this data, and create a Hosted service from it. Only then will you have supportsStatistics enabled.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.