docs/en/sql-reference/sql-functions/bitmap-functions/bitmap_hash64.md
Calculates a 64-bit hash value for any type of input and returns a bitmap containing the hash value. It is mainly used to load non-integer data into the BITMAP field of the StarRocks table via Stream Load. For example:
cat data | curl --location-trusted -u user:passwd -T - \
-H "columns: dt,page,device_id, device_id=bitmap_hash64(device_id)" \
http://<fe_host>:8030/api/test_db/tbl1/_stream_load
BITMAP BITMAP_HASH64(expr)
expr: The input can be of any data type.
Returns a value of the BITMAP data type.
MySQL > select bitmap_count(bitmap_hash64('hello'));
+--------------------------------------+
| bitmap_count(bitmap_hash64('hello')) |
+--------------------------------------+
| 1 |
+--------------------------------------+
select bitmap_to_string(bitmap_hash64('hello'));
+------------------------------------------+
| bitmap_to_string(bitmap_hash64('hello')) |
+------------------------------------------+
| 10760762337991515389 |
+------------------------------------------+
BITMAP_HASH64,BITMAP