With the Arcade language, I try to feed a dictionary with several fields of which one field is of type date.
This dictionary is fed from a feature service.
Here is an example of my code:
If I return the contents of my dictionary, I can see the date value.
But if I try to flip it this way:
return FeatureSet(Text(table_Dict))
Date values not appearing !
Can someone help me with this?
Solved! Go to Solution.
Had the same issue. @Anonymous User solved it for me re requirement for unix timestamp https://community.esri.com/t5/developers-questions/arcade-dictionary-to-featureset/td-p/1047117
Had the same issue. @Anonymous User solved it for me re requirement for unix timestamp https://community.esri.com/t5/developers-questions/arcade-dictionary-to-featureset/td-p/1047117
Thanks @DavidPike - I have seen this come up a lot recently with increased adoption of Data Expressions. I'm thinking I'll submit an issue to see if a date field can be included in the FeatureSet example in the Arcade documentation.
I think that would be really helpful.
As far as I am aware this is still not in the documentation (definitely not in the samples that the link in the Data Expression directs you to) and this would still be very helpful to include!
Thank you both. 😀
Have a nice day
Hello pls i need a line to download and install this on my pc ARCGIS DESKTOP
@MICHAELOBIDA : I would suggest you to write a new question, rather than commenting in replies to unrelated threads.
For instructions, please check How to ask a question - Esri Community
For anyone else who stumbles along this problem, here's an explanation and alternative. You can vote on this idea to hopefully get it fixed: https://community.esri.com/t5/arcgis-online-ideas/arcade-allow-date-values-in-date-fields/idc-p/1236...
With this week's update to Arcade and ArcGIS Dashboards, date fields in feature set constructors now just work. You no longer have to pass dates in as EPOCH if you pass the dictionary into the FeatureSet() function (which as of this release accepts a dictionary as opposed to only text based JSON).
Instead of:
return FeatureSet(Text(dict))
Do this:
return FeatureSet(dict)
Learn more in this blog post.
NOTE: For Enterprise users, this update is targeted for 11.2