random_bytes
random_bytesβ
descriptionβ
The random_bytes
function generates a sequence of random bytes.
Syntaxβ
VARCHAR random_bytes(INT len)
Parametersβ
- len: The
random_bytes
function takes a single argument, which specifies the length of the generated random byte sequence.
exampleβ
mysql> select random_bytes(7);
+------------------------------------------------+
| random_bytes(7) |
+------------------------------------------------+
| 0x53edd97401fb6d |
+------------------------------------------------+
keywordsβ
RANDOM BYTES