TIMESTAMP vs. DATETIME for `created` and` updated` columns

I use PHP / MySQL, and I always used DATETIME to store values createdand updated, but I think there might be a better way.

Should I use TIMESTAMP instead, and if so, why?

+3
source share
2 answers

The documentation states:

TIMESTAMP UTC UTC . ( TIMESTAMP, , DATETIME.) - . , 9.6 " MySQL". , , . TIMESTAMP, , . , . time_zone.

, TIMESTAMP, , / UTC, .

+1

UTC . , , , , . , .

0

Source: https://habr.com/ru/post/1774713/


All Articles