Retrieve the current date and time in a particular time zone

suggest change

This fetches NOW() in the session time zone, then in India Standard Time, then in UTC. Named zones such as Asia/Kolkata work only after the time-zone tables are loaded.

SELECT NOW();
SET time_zone='Asia/Kolkata'; 
SELECT NOW();
SET time_zone='UTC'; 
SELECT NOW();

Feedback about page:

Feedback:
Optional: your email if you want me to get back to you:



Table Of Contents