ArcGIS Online not displaying UTC time in local time format

736
1
Jump to solution
02-17-2020 04:19 PM
JackSilburn
New Contributor III

Hello.

I am trying to publish data to an ArcGIS Online 'Table (Hosted)' layer. Some of the fields contain UTC formatted times.

Below is JSON text which I am posting via the Update Features API:

'{"attributes":

   {

   \'key\': \'value\',

   \'timestamp\': \'2020-02-17 13:49:00+00:00\',

   \'key1\': \'value1\'

   }

},

'{"attributes":

...

}'

It is my understanding that default AGOL behavior is to display UTC times in the user's local (or browser) time format. However this is not the case:

The above times were not generated in the AM.

By adjusting for the time difference manually, I get my correct local time.

It is bizarre because I have implemented a similar process, where UTC time data is displaying as expected.

These are the field settings for both the non-working and working hosted tables:

This is how the working JSON is being posted:

\'Timestamp\': \'2020-02-17 07:04:04.737841+00:00\'

Any idea why the default behavior of AGOL is not occurring? Is there a way to edit the settings to fix this issue?

Thanks.

ArcGIS Online

ArcGIS REST API

0 Kudos
1 Solution

Accepted Solutions
JackSilburn
New Contributor III

My mistake.

In my code I was converting the time to UTC. But the time was already in UTC format! So I think ArcGIS Online was doing its job, but I was giving it UTC converted to UTC... 

Issue resolved.

View solution in original post

0 Kudos
1 Reply
JackSilburn
New Contributor III

My mistake.

In my code I was converting the time to UTC. But the time was already in UTC format! So I think ArcGIS Online was doing its job, but I was giving it UTC converted to UTC... 

Issue resolved.

0 Kudos