0

I am inserting data via MySQL in local server CURRENT_TIMESTAMP() saves my country time.

Now I'm working in a hosting and CURRENT_TIMESTAMP() is 5 hours higher.

I have added

SET time_zone = '-5:00'

But it doesn't fix the problem

How do I fix this?

Dharman
  • 30,962
  • 25
  • 85
  • 135
Joe
  • 1
  • Does this answer your question? [How do I set the time zone of MySQL?](https://stackoverflow.com/questions/930900/how-do-i-set-the-time-zone-of-mysql) – Martin Oct 05 '20 at 23:17

1 Answers1

1

I think you have to use UPDATE.

Try this:

UPDATE yourTable SET time_zone = '-5:00'
Dharman
  • 30,962
  • 25
  • 85
  • 135
Jakob
  • 1,858
  • 2
  • 15
  • 26
  • I need to use this timezone for the whole database – Joe Oct 20 '18 at 23:25
  • 1
    @Joe I am sorry, but you didn't asked very well... So I it is difficult to undestand what you want to do. Please edit your question and describe your problem a little bit more. – Jakob Oct 21 '18 at 00:56