Note:
This topic has been translated from a Chinese forum by GPT and might contain errors.Original topic: BIGINT 时间戳如何设置TTL属性

[TiDB Usage Environment] Production Environment
[TiDB Version] V6.5.0
I want to set TTL to automatically delete data, but my data table only has a BIGINT attribute for the second timestamp. When I use the following SQL statement to set it, an error is reported. How should I handle it?
CREATE TABLE t2 (
id int PRIMARY KEY,
created_at BIGINT(16)
) TTL = FROM_UNIXTIME(created_at) + INTERVAL 3 MONTH;
The error message is as follows:
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your TiDB version for the right syntax to use line 4 column 23 near "(created_at) + INTERVAL 3 MONTH"