MySQL Current Time

MySQL Current_Time and Current_Time() are the MySQL Date Functions, which are useful to return the current time in HH:MM:SS or HHMMSS string format. Let us see how to use these Current Time functions in MySQL with example. The basic syntax of the Current time in MySQL is as shown below:

CURRENT_TIME;

CURRENT_TIME();

MySQL CURRENT_TIME Example

The following statements show you how to use these MySQL Current time functions.

TIP: Both these Date Functions are the synonyms of CURTIME(). All these three functions return the same MySQL output.

SELECT CURRENT_TIME;

SELECT CURRENT_TIME();
MySQL Current Time Function 2

As you can see, both the above statements return the current time in HH:MM:SS format. The below statements show you what happens when we add a few seconds to the MySQL Current_Time function.

SELECT CURRENT_TIME, CURRENT_TIME + 0, CURRENT_TIME + 5;

SELECT CURRENT_TIME(), CURRENT_TIME() + 0, CURRENT_TIME() + 32;

As you can see from the below, they added those extra seconds to the current time and displaying the current time in HHMMSS string format

MySQL Current Time Function 3