AnsweredAssumed Answered

How to display more than 1000 features

Question asked by farajallah2012 on Apr 15, 2015
Latest reply on Apr 15, 2015 by jskinner-esristaff

As you know there is a limit on the maximum number of features you can show on a map, is there a way to go beyond this limit?

 

query = new Query();
fl=FeatureLayer.SELECTION_NEW;

allCarolinaCounties = new FeatureLayer("http://server.url/MapServer/0", {
      mode: FeatureLayer.MODE_ONDEMAND,
     outFields: ["field1", "field2", "field3"]
});
allCarolinaCounties.setDefinitionExpression("field4='value'");

c
allCarolinaCounties.setSelectionSymbol(highlightSymbol);


map.addLayer(fl);
map.addLayer(allCarolinaCounties);

// then in another place
function showPop(){
     var pop=$("#tpop").val();
     query.where="field1 = '"+pop+"'";
     allCarolinaCounties.clearSelection();
     allCarolinaCounties.selectFeatures(query, fl, function(features){ /*do nothing*/ });
} // showPop

Outcomes