Show / Hide Table of Contents

Property WhereClause

WhereClause

Gets or sets the attribute expression that defines features to be included in the query.

Declaration
public string WhereClause { get; set; }
Property Value
Type Description
System.String

The where clause of the query.

Remarks

The where clause should follow standard SQL syntax similar to that discussed in the document SQL reference for query expressions used in ArcGIS.

If the where clause includes dates, they must be correctly formatted based on the geodatabase datasource used in the service. Refer to Dates and time for date formats expected by different data sources.

ArcGISFeatureTable objects expect that any GlobalID or Guid parameters in the string that is used as the where clause are formatted as: '{XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX}'. All characters are uppercase, wrapped in curly braces and surrounded by single quotes.

If the where clause is used to populate a OgcFeatureCollectionTable, you can use a CQL2-TEXT or CQL2-JSON string as defined in the document OGC API - Features - Part 3.

Applies to

Platforms and versions
TargetVersions
.NET Standard 2.0100.3 - 200.8
.NET100.13 - 200.8
.NET Windows100.13 - 200.8
.NET Android200.0 - 200.8
.NET iOS200.0 - 200.8
.NET Framework100.0 - 200.8
Xamarin.Android100.0 - 100.15
Xamarin.iOS100.0 - 100.15
UWP100.0 - 200.8
Relevant samples
Feature layer query: Find features in a feature table which match an SQL query.
Find service areas for multiple facilities: Find the service areas of several facilities from a feature service.
Map image layer tables: Find features in a spatial table related to features in a non-spatial table.
In This Article
Back to top Copyright © 2022 Esri.