UUID and TIMEUUID
hex_digit
is a hexadecimal digit ([0-9a-fA-F]
).
- Columns of type or
TIMEUUID
can be part of the PRIMARY KEY
. - Implicitly, values of type
UUID
and TIMEUUID
datatypes are neither convertible nor comparable to other datatypes. TIMEUUID
s are version 1 UUIDs: they include the date and time of their generation and a spatially unique node identifier.
cqlsh:example> CREATE TABLE devices(id UUID PRIMARY KEY, ordered_id TIMEUUID);
cqlsh:example> INSERT INTO devices (id, ordered_id)
VALUES (123e4567-e89b-42d3-a456-426655440000, 123e4567-e89b-12d3-a456-426655440000);
cqlsh:example> SELECT * FROM devices;