Quantcast
Channel: ASP.NET Core
Viewing all articles
Browse latest Browse all 9386

How to properly store date and time for events?

$
0
0

I am facing a hard time understanding when to use local time vs UTC.

say I have a web application that user can be logged in from multiple time zones,

I will be dealing with two scenarios here,

Login/logout events dates/times

Appointments, some of the users might have different satellite locations and they might be distributed in more than TimeZone.

I just can not figure out the proper way to handle date/times.

shall I store local times with user offset from UTC based on Timezone ID or

Just store everything based on UTC along with UTC offset and do the conversion to TimeZones in the presentation layer?


Viewing all articles
Browse latest Browse all 9386

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>