Date presentation question - why some users see dates differently?

0
We have an App running for several years now, and recently something strange occurs…..  we have a user in the App registering a person, and selecting a B-day; let say 11-7-1980 we have scheduled logic which creates a text-file, including the B-day, representing it as: 10 july 1980 when we use our Admin access to look at the field it states: 10-7-1980 23:00 when i check the UTC value it says”10-7-1980 22:00   The App is on GMT +1 (Amsterdam) All users are on GMT +1 (Amsterdam) This does happen with some users, on some occasions, but as far as I can tell at thin moment, without a discernable pattern WHO is the Time-Traveler ?
asked
3 answers
3

Could Citrix also be of influance here? Because if I recol correctly if you are on Citrix and open a browser the browser time is probably the time of the Citrix server. And then it depends on how that one is configured.

Regards,

Ronald

 

answered
1

Hi Lex,

We all are time travelers!

Especially when the winter time starts, dates we entered two weeks ago are now shown as an hour earlier… And that's because we massively went from UTC+2:00 to UTC+1:00. So that “10-7-1980 22:00 (UTC)” was shown two weeks ago as “11-7-1980 00:00 (UTC+2:00)” and now as “10-7-1980 23:00 (UTC+1:00)”. Makes sense, right?

Tip: if the time component is not relevant (like for birthdays), always set Localize option to false. Then the date is stored as it is entered and always shown like that.

Hopefully you can work it out from here knowing this!

Kind regards,

Johan

Update:

And therefore, only people who entered their birthdate during summertime have their birthdate exported on the wrong date during the winter. The other way around is just at 1:00 (UTC+2:00) instead of 0:00 (UTC+1:00), so that will be on the same date. 

 

answered
1

Converting the dates in a string happens in a microflow, and thus the server time is leading, not the user time zone or the browser-time. Also formatting taking the timezone into account or the  ....UTC() function will make a difference. When the data is added by who under which timezone setting is also affecting which value is stored. In the end every date is stored UTC in the database.

So my suggestion is; take a look at the database values. If these are correct but the output is wrong, then its related to used expressions and set (or lack of set) timezone. 

For more background take a look at this learning path; https://academy.mendix.com/link/module/374/lecture/3046/7.1-Introduction

answered