Manipulations with Table TTL
Note
If you are looking for details on using TTL for managing old data, check out the Manage Data with TTL user guide. The docs below demonstrate how to alter or remove an existing TTL rule.
MODIFY TTL
You can change table TTL with a request of the following form:
REMOVE TTL
TTL-property can be removed from table with the following query:
Example
Consider the table with table TTL
:
Run OPTIMIZE
to force TTL
cleanup:
Second row was deleted from table.
Now remove table TTL
with the following query:
Re-insert the deleted row and force the TTL
cleanup again with OPTIMIZE
:
The TTL
is no longer there, so the second row is not deleted:
See Also
- More about the TTL-expression.
- Modify column with TTL.