MariaDB: MAKETIME Function
This MariaDB tutorial explains how to use the MariaDB MAKETIME function with syntax and examples.
Description
The MariaDB MAKETIME function returns the time for a certain hour, minute, second combination.
Syntax
The syntax for the MAKETIME function in MariaDB is:
MAKETIME( hour, minute, second )
Parameters or Arguments
- hour
- The hour value used to create the time.
- minute
- The minute value used to create the time.
- second
- The second value used to create the time.
Note
- Time values range from '-838:59:59' to '838:59:59'.
Applies To
The MAKETIME function can be used in the following versions of MariaDB:
- MariaDB 10
Example
Let's look at some MariaDB MAKETIME function examples and explore how to use the MAKETIME function in MariaDB.
For example:
SELECT MAKETIME(8,49,13); Result: '08:49:13' SELECT MAKETIME(14,23,0); Result: '14:23:00' SELECT MAKETIME(23,59,59); Result: '23:59:59' SELECT MAKETIME(838,59,59); Result: '838:59:59' SELECT MAKETIME(-838,59,59); Result: '-838:59:59'
Advertisements