Practical limit on size of FeatureLayer.definitionExpression?

105
1
02-07-2019 08:22 AM
TonyGraham
New Contributor III

For my use case, I'll never know how many features I'm dealing with or what will be the content and type of the attributes that I'll need to filter on.

For this particular test, I'm trying to display, say, 20,000 of 21,000 features from a feature service having a maxRecordCount of 1,000.  My definitionExpression is an enormous "IN()" statement.  Without a defintionExpression, I'll see all 21,000 features.  With a definitionExpression of below maxRecordCount, I _think_ I may be seeing my desired features.  With a defintionExpression of 20,000, after significant delay, I often don't see any features, or perhaps I'll see a few.  (Having written this, I'm seeing that more points are starting to show up.  Maybe if I let it go on long enough, it'll work.  Success will be hard to validate.)

I believe that the prescription for my pain is to "stop doing that."

Is there a hard limit?

Should switch to subdividing my filter values into smaller chunks, querying manually, and appending the results to my FeatureLayer?

0 Kudos
1 Reply
TonyGraham
New Contributor III

If the latter option (manually perform queries based on subsetted filter values), how would I best populate the feature layer?  Would I be forced to use a client-side feature layer and update its source?  

0 Kudos