MINUTE() Function in MySQL
MINUTE() function :
This function in MySQL is used to return the minutes part for a specified time or date time value. The range of minute value is from 0 to 59. For example, if the specified time is β09:12:23β, this function will return 12 minute.
Syntax :
MINUTE(datetime)
Parameter :
This method accepts a parameter as given below as follows.
- datetime β Specified time or date time value to extract the minute from.
Returns :
It returns the minutes part for a specified time or date time value.
Example-1 :
Getting the minute β32β from the specified date and time β2020-11-24 09:32:12β.
SELECT MINUTE("2020-11-24 09:32:12");
Output :
32
Example-2 :
Getting the minute β12β from the specified time β06:12:23β.
SELECT MINUTE("06:12:23");
Output :
12
Example-3 :
Getting the minute β59β from the specified time β838:59:59β.
SELECT MINUTE("838:59:59");
Output :
59
Application :
This function is used to return the minute part for a specified time or date time values.