DateTime, Timestamp, Time and Date What is the difference

1.DATE only stores a date: The date

2.TIME only stores the time of day: when minutes and seconds

3.DATETIME storage date + time, DATETIME is formatted as YYYY-MM-DD HH: MM: SS, the effective range of from 1000 to 9999 (and anything in between). Accurate to minutes and seconds, it used to make stamps. 8 bytes of storage.

4.TIMESTAMP: getting from the database TIMESTAMP looks similar, but it's really just a unix timestamp frontier, its effective range from 1970 to 2038.

Guess you like

Origin www.cnblogs.com/weihl/p/12171932.html