The Zurich release has arrived! Interested in new features and functionalities? Click here for more

Set timezone based on user location

Prasad43
Tera Guru

Hello folks,

Is there any way to set the time zone in user table based on the location. Any thoughts on this.

(When a new user is created, I want to set time zone based on the location selected. Is there any way to find the related time zone based on location.)

 

Thanks

 

4 REPLIES 4

Mike_R
Kilo Patron
Kilo Patron

On the location table, there is a time zone field. Populate that

Mike_R_0-1667926222162.png

 

Then just create a business rule or flow on the sys_user table to set the time zone in the user profile equal to time zone on location

Sample BR:

Mike_R_0-1667926545692.png

 


Mike_R_2-1667926594656.png

 

current.time_zone = current.location.time_zone;

 

 

OOTB all time zones are empty for location table. How to populate time zones for all locations.

OOTB there is a BR which is populating Latitude and Longitude. Is there any way to populate time zones similarly. 
We can use GOOGLE API, but it involves costing.

Ankur Bawiskar
Tera Patron
Tera Patron

@Prasad43 

You first need to understand how are you loading the users in sys_user? Are you using LDAP for this?

What's the process?

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader