Hello,
Is it possible to bring the Arcade Date function into full reality?
In working with the Arcade Date function in Calculate Field the valid month range of 0-11 seems absolutely off especially when the rest of the past variables are based on reality. Year and Day components of the date are the normal values but the month is a 0 based number ...
Time values obviously can have a valid 0 value but month doesn't seem like a good candidate for this.
Am I missing something?
Thanks for the consideration
Tom
Hello @ThomasHoman , my apologies if this is rather unhelpful, but no, you are not missing something.
https://developers.arcgis.com/arcade/function-reference/date_functions/#date1
"month: Number - The month (0-11) where 0 is January and 11 is December."
@ChrisUnderwood Obviously any edits to this would break a bunch of existing code but is there a way to correct (idea submittal) or can you share specific reasons for this odd case?
@ThomasHoman If this Idea gains enough Kudos then it should get considered, but as you say, changing it would break lots of things. I presume there is some historical reason for using 0-11, but I don't know any details.
Meanwhile, the ISOMonth function does appear to offer a 1-12 Index instead,
https://developers.arcgis.com/arcade/function-reference/date_functions/#isomonth
And there are some other methods described in this Knowledge Article.
https://support.esri.com/en-us/knowledge-base/how-to-extract-names-of-the-month-from-a-date-field-us...
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.