Select to view content in your preferred language

multiple definitions on a Feature Layer filter

825
3
06-09-2011 07:57 AM
SangamLama
Emerging Contributor
Howdy,

I'm wondering if I can do something like "500000> POP2000 > 1000000" instead of  "POP2000 > 1000000" for a filter? Basically, trying to get only certain set of features back with both upper and lower limit. A good use case would be to find out which parcels are between area 500 sq feet to 1000 sq feet.

thanks
0 Kudos
3 Replies
DominiqueBroux
Esri Frequent Contributor
Try "500000< POP2000 AND POP2000 < 1000000"
0 Kudos
TerryGiles
Frequent Contributor
Look at the Where property of a FeatureLayer.  Documentation says 'Any legal SQL where clause operating on the fields in the layer is allowed' so you should be able to do something like

  FeatLayer.Where = "POP2000 > 500000 AND POP2000 < 1000000";


What's considered legal SQL statement will depend on the underlying data source.

TG
0 Kudos
SangamLama
Emerging Contributor
thanks to you both.

Look at the Where property of a FeatureLayer.  Documentation says 'Any legal SQL where clause operating on the fields in the layer is allowed' so you should be able to do something like

  FeatLayer.Where = "POP2000 > 500000 AND POP2000 < 1000000";


What's considered legal SQL statement will depend on the underlying data source.

TG
0 Kudos