Symbolising date ranges capped at 100,000?

02-09-2021 03:14 AM
Labels (1)
New Contributor II

//areas which are surveyed 30 days ago or less belong in the first group
if (DateDiff(Now(), Date($feature.CreationDate), 'months') <= 😎 {
return "Surveyed within the last 8 months" }
//areas which are surveyed more than 30 days but less than 100 days ago belong in the second group
else if (DateDiff(Now(), Date($feature.CreationDate), 'months') > 8 &&
DateDiff(Now(), Date($feature.CreationDate), 'months') < 10) {
return "Surveyed between 8 to 10 months ago" }

else if (DateDiff(Now(), Date($feature.CreationDate), 'months') > 10 &&
DateDiff(Now(), Date($feature.CreationDate), 'months') < 12) {
return "Surveyed between 10 to 12 months ago" }
//areas which do not satisfy any of the given conditions belong in the fourth group
else {
return "None of these Date Ranges" }


I'm using the above expression to symbolise on inspections, however I am noticing this seems to cap at 100,000 inspections when in the layer there is around 300,000.

Has anyone else encountered this and if so is there a work around or is this just how it is?


Thank you for any contributions

Tags (2)
0 Kudos
2 Replies
New Contributor II

I have ran into a similar issue before. I was using Dashboards to filter a list and it was limiting the returns. I used AGO Assistant to go into the JSON and modify the max return number. Not sure if you are trying to use in WebMap, App, Dashboards, etc., but here is what I modified: 

esrihelp.JPG (Which could be different on your Portal Item depending on your platform. Not sure if it will be the same or not.)

Disclaimer: I recommend saving a copy and modifying the JSON of the copy to prevent any errors in your production Portal Item. Also, something to keep in mind is the more items you load you could experience performance issues displaying the data. Food for thought...

Ryan O'Quinn
0 Kudos
Esri Esteemed Contributor

Hi @map16jamie ,

A quick note on performance. You should not carry out the same calculation multiple times. It would be better to do something like this:

var months = DateDiff(Now(), Date($feature.CreationDate), 'months');

if (months <= 😎 {
    return "Surveyed within the last 8 months";
} else if (months > 8 && months <= 10) {
    return "Surveyed between 8 to 10 months ago"; 
} else if (months > 10 && months <= 12) {
    return "Surveyed between 10 to 12 months ago";
} else {
    return "Surveyed more than 12 months ago";


I also have used AGO assistant in the past, not to change the maxPaginationRecords, but to define the symbols in case some were missing.  Worked like a charm, but remember what @Roquinn advised (make a copy of the web map since you can end up making it invalid).

0 Kudos