Divyesh Patel asked
How to get current time of system using mysql query.
I try out NOW() function and it’s return
but my system time is
How to get to exact system time?
How to implement in mysql query?
There are a number of ways to do this according to the MySQL documentation.
Following the documentation, open your
my.cnf file (MySQL configuration). On Linux, that is usually under
/etc/mysql/my.cnf. On Windows, see other places to look.
Add this line and restart MySQL.
[TIMEZONE] with the timezone you prefer to use.
The value can be given as a string indicating an offset from UTC, such as ‘+10:00’ or ‘-6:00’.