MySQL supports a variety of data types to support and store different kind of data and to perform different operations on it.
Supported data types can be majorly categorized into following types:
Date and Time Types
This data type is used to store date and time in its originality and to perform operations on them. Besides standard types, there is also TIMESTAMP which allow us memorizing the timestamp of a row's modification.
Following date and time types are accepted:
- TIME: MYSQL represents time in 'HH:MM:SS'.
- DATE: MYSQL represents date in 'YYYY-MM-DD'.
- TIMESTAMP: It contains both date and time as, 'YYYY-MM-DD HH:MM:SS'.
- YEAR: it is used to represent year value as 'YYYY'.
Comments
No comments have been made yet.
Please login to leave a comment. Login now