The following SQL built-in functions are supported in MySQL 9.2
and later, and can be called directly from the
mysql
namespace. These are described in the
following list, along with their analogous SQL functions:
rand()
(MySQLRAND()
): Returns a random floating-point valuev
in the range 0 <=v
< 1.0.sleep(
(MySQLseconds
)SLEEP()
): Pauses forseconds
seconds, then returns 0.uuid()
(MySQLUUID()
): Returns a Universal Unique Identifier (UUID).isUUID(
(MySQLargument
)IS_UUID()
): Returns 1 if theargument
is a valid string-format UUID, 0 if it is not a valid UUID, andNULL
if the argument isNULL
.