This tutorial explains how to use the MySQL CURRENT_TIMESTAMP function with syntax and examples.
Description
The MySQL CURRENT_TIMESTAMP function returns the current date and time.
Syntax
The syntax for the CURRENT_TIMESTAMP function in MySQL is:
Parameters or Arguments
There are no parameters or arguments for the CURRENT_TIMESTAMP function.
Note
The CURRENT_TIMESTAMP function will return the current date as a 'YYYY-MM-DD HH:MM:SS' format, if used in a string context.
The CURRENT_TIMESTAMP function will return the current date as a YYYYMMDDHHMMSS format, if used in a numeric context in versions of MySQL prior to MySQL 4.1.13.
The CURRENT_TIMESTAMP function will return the current date as a YYYYMMDDHHMMSS.uuuuuu format, if used in a numeric context in versions of MySQL 4.1.13 and newer.