Good morning,
Our Open Data portal shows the Date Updated when the last time our Hosted Feature Layers were updated and not the date of the data.
I had Notebook at one time that would update this date to show our data is dynamically updated weekly but can't find it.
Does anyone have a sample of how to update this value? We can't currently use editor tracking fields so I would like script that does it to show the users our data is updated frequently.
Thank you
Solved! Go to Solution.
This is how I was able to update the data via python
#connect to GIS
from arcgis.gis import GIS
gis = GIS("https://website.maps.arcgis.com/", "UserName", "**********")
#Get user that owns folder
user = gis.users.get("UserName")
#Get list of items
list = user.items(folder='Open Data')
for i in list:
i.update(item_properties = {'accessInformation': "COS"})
Updating the accessinformation sets the updated date to today
This is how I was able to update the data via python
#connect to GIS
from arcgis.gis import GIS
gis = GIS("https://website.maps.arcgis.com/", "UserName", "**********")
#Get user that owns folder
user = gis.users.get("UserName")
#Get list of items
list = user.items(folder='Open Data')
for i in list:
i.update(item_properties = {'accessInformation': "COS"})
Updating the accessinformation sets the updated date to today