In Cassandra, how can you define a table with automatic expiration of data (TTL) for a column named 'message'? - Study24x7
Social learning Network
4 followers study24x7 04 Nov 2024 11:08 AM study24x7 study24x7

In Cassandra, how can you define a table with automatic expiration of data (TTL) for a column named "message"?

A

CREATE TABLE messages (id UUID PRIMARY KEY, message text, TTL int)

B

CREATE TABLE messages (id UUID PRIMARY KEY, message text) WITH default_time_to_live=3600

C

ALTER TABLE messages ADD TTL (message, 3600)

D

None of the above

study24x7
Write a comment
Related Questions
500+   more Questions to answer
Most Related Articles