Name
LOCALTIME( )
Synopsis
LOCALTIME( )
This function returns the current system date in yyyy-mm-dd
hh:mm:ss format. You can use it in
SELECT
statements as shown here, in
INSERT
and UPDATE
statements to
set a value, or in a WHERE
clause. This statement
is available as of Version 4.0.6 of MySQL.
Incidentally, the parentheses are not
required. This function is synonymous with LOCALTIMESTAMP()
and NOW( )
.
SELECT LOCALTIME( ); +----------------------+ | LOCALTIME( ) | +----------------------+ | 2005-01-10 14:27:41 | +----------------------+
Get MySQL in a Nutshell now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.