MySQL CURRENT_TIME() Function

MySQL | CURRENT_TIME() Function: Learn about the CURRENT_TIME() function, how it works, its usages, syntax, and examples.
Submitted by Apurva Mathur, on October 08, 2022

CURRENT_TIME() Function

As the name suggests, the CURRENT_TIME() function is used to get the current time. It is a synonym of the CURTIME() function.

CURRENT_TIME() Syntax

SELECT CURRENT_TIME();

CURRENT_TIME() Parameter(s)

  • Since this function returns the current time so therefore no parameters are given in this function.

CURRENT_TIME() Return Value

This function will return the current time. By default, it returns the time in HH:MM:SS format, and when you add some numeric value in this current time then it returns the value in HHMMSS format.

MySQL CURRENT_TIME() Function Example 1

SELECT CURRENT_TIME();
Example 1: MySQL CURRENT_TIME() Function

MySQL CURRENT_TIME() Function Example 2

SELECT CURRENT_TIME()+4;
Example 2: MySQL CURRENT_TIME() Function


Comments and Discussions!

Load comments ↻





Copyright © 2024 www.includehelp.com. All rights reserved.