ClickHouse/tests/queries/0_stateless/02310_uuid_v7.sql

9 lines
366 B
MySQL
Raw Normal View History

-- Tests function generateUUIDv7
SELECT toTypeName(generateUUIDv7());
2024-04-28 09:50:42 +00:00
SELECT substring(hex(generateUUIDv7()), 13, 1); -- check version bits
SELECT bitAnd(bitShiftRight(toUInt128(generateUUIDv7()), 62), 3); -- check variant bits
SELECT generateUUIDv7(1) = generateUUIDv7(2);
SELECT generateUUIDv7() = generateUUIDv7(1);
SELECT generateUUIDv7(1) = generateUUIDv7(1);