Time Stamp Issue
I have noticed that the timestamp is taken in mysql is wrong for columns under type current_timestamp and it 3 hrs back to the actual time.
Steps taken :
1. Added date_default_timezone_set("Asia/Kolkata"); in PHP - It works only for php scripts
I have columns in table with timestamp type. Those fields are updated based on server clock and it is 3 hrs backward.
-
Is your mysql time_zone set to your server time or local time/are those times different? 0 -
I'd second what @ReggieR suggests, this would use server time. 0 -
I'd second what @ReggieR suggests, this would use server time.
Server is in Europe and i need to use IST Timing. Any solution for this.?0 -
If the mysql configuration file is different from the IST timing I'd suggest starting there. sudo vim /etc/mysql/my.cnf Adjust the default-time-zone here for your mysql db. 0
Please sign in to leave a comment.
Comments
4 comments