ArcGIS Pro 2.7 API Reference Guide
SetFilterWhereClause Method (RealtimeFeatureClass)

ArcGIS.Core.Data.Realtime Namespace > RealtimeFeatureClass Class : SetFilterWhereClause Method
A string representing SQL where clause.
Sets a filter on this table so that only features matching this filter will be streamed by the service. This method must be called on the MCT. Use QueuedTask.Run.
Syntax
public void SetFilterWhereClause( 
   string filterWhereClause
)
Public Sub SetFilterWhereClause( _
   ByVal filterWhereClause As String _
) 

Parameters

filterWhereClause
A string representing SQL where clause.
Exceptions
ExceptionDescription
This method or property must be called within the lambda passed to QueuedTask.Run.
Remarks
Filters applied on the feature class are not persisted. They are in-memory only. To persist a filter, use the equivalent SetDefinitionQuery(...) method on the StreamLayer

Check RealtimeDatastore.GetFilterSQLSyntax to find out SQL syntax and supported functionality for the real-time datasource.

Setting a filter removes all existing features and starts from blank with the new filter.

It is not a filter that gets applied on the client side, rather it gets set to the connection itself and realtime service only streams features that match this criteria.

Requirements

Target Platforms: Windows 10, Windows 8.1

See Also

Reference

RealtimeFeatureClass Class
RealtimeFeatureClass Members