How to filter the data on a month based on the time zones users?
I am using MongoDB database
For example an entry with date and time in UTC at night. In UTC the entry may take another day.
I need to filter further for example, the entries by months. There is a risk that some data will terauda due to the fact that different time zones. In such cases, to do? Like let the user to filter the records in his time zone?
Record time zone as +03 or -07, and in the filter add or subtract the time zone value to the utc value.
ie, in the dB a value of 14:00, when you filter all records older than or equal to 14:00 time user
for utc time >= 14:00
for +03 time >= 17:00
for -07 time >= 07:00