XXHASH_32
xxhash_32â
descriptionâ
Syntaxâ
INT XXHASH_32(VARCHAR input, ...)
Return the 32 bits xxhash of input string.
Note: When calculating hash values, it is more recommended to use xxhash_32
instead of murmur_hash3_32
.
exampleâ
mysql> select xxhash_32(NULL);
+-----------------+
| xxhash_32(NULL) |
+-----------------+
| NULL |
+-----------------+
mysql> select xxhash_32("hello");
+--------------------+
| xxhash_32('hello') |
+--------------------+
| -83855367 |
+--------------------+
mysql> select xxhash_32("hello", "world");
+-----------------------------+
| xxhash_32('hello', 'world') |
+-----------------------------+
| -920844969 |
+-----------------------------+
keywordsâ
XXHASH_32,HASH