You are sharing a web layer or web map to ArcGIS Online or ArcGIS Enterprise that includes a layer with a spatial clause in one or more definition queries. Because spatial clauses cannot be read by the server, and because this would impact map and layer processing and drawing, an error is returned.
Solutions
Do one of the following:
- Turn off the definition query containing the spatial clause. Right-click the layer and select Properties to open the Layer Properties window. On the Definition Query tab, click Clear active query
and click Apply to have no query applied.
- If the spatial clause is not needed, remove the clause from the definition query.
- Consider alternate methods for filtering features or items before publishing, such as creating a selection layer.
Additional information
For working with definition queries, see Filter features with definition queries.
For more information, see Analyze your GIS resource.