Question

Converting UTC to Local Time, error by 2hr

  • 6 April 2020
  • 1 reply
  • 10 views

Badge +7

I am downloading my survey123 data from ArcGIS Online Feature Layer, and trying to convert the stored UTC into Local Time, and I have been provided this code, from this thread

@TimeZoneSet(@TimeZoneSet(@Value(shift_start),local),utc,convert)

 

It initially looked good, but now I am looking closer at the results I am seeing the converted data is all out by +2hr. Where I should be seeing it converted to 8.30am,  they are all showing as 10.30am. 

And today we have started 'daylight savings' where we adjust our clocks by 1hr, my dates are instead showing as +4hr out! I am pulling my hair out as I have no idea where to start looking to resolve!

I am unsure why this could be? Is there an adjustment I should be making? Is it a setting in FME? I am in Sydney Australia time zone.


1 reply

Userlevel 1
Badge +21

That expression converts from local to utc, you  need to convert from utc to local

@TimeZoneSet(@TimeZoneSet(@Value(shift_start),utc),local,convert)

Reply