EN
MySQL - MINUTE() function example
0
points
In this article, we would like to show you MINUTE() function example in MySQL.
Syntax:
SELECT MINUTE('YYYY-MM-DD hh:mm:ss');
Where:
YYYY- four-digit year format, e.g.2021,MM- month number (counted from01to12),DD- day number (from01to31- depending on the month),hh- hour number (from00to24),mm- minute number (from00to59),ss- second number (from00to59).
Practical example
In this example, we will use MINUTE() function to display only a minute from a DATETIME value.
Query:
SELECT MINUTE('2021-01-01 11:41:31');
Result: