【发布时间】:2020-12-28 23:49:13
【问题描述】:
我正在运行最新版本的 TimescaleDB。
在文档中我发现了这个:https://docs.timescale.com/latest/using-timescaledb/compression#quick-start
当我跑步时:
CREATE TABLE con_details (LIKE deprecated_consumption_details INCLUDING DEFAULTS INCLUDING CONSTRAINTS INCLUDING INDEXES);
SELECT create_hypertable('con_details', 'date');
ALTER TABLE con_details SET (
timescaledb.compress,
timescaledb.compress_segmentby = 'meter_id'
);
SELECT add_compression_policy('con_details', INTERVAL '7 days');
最后一行报错:
SQL Error [42883]: ERROR: function add_compression_policy(unknown, interval) does not exist
Hint: No function matches the given name and argument types. You might need to add explicit type casts.
Position: 9
还有文档中的其他功能,例如:
SELECT * FROM hypertable_detailed_size('con_details');
给我错误:
ERROR: function hypertable_detailed_size(unknown) does not exist
TimescaleDB 扩展当然已启用(创建和查询 Hypertable 工作正常...)
【问题讨论】:
-
您使用哪个版本的 TimescaleDB?
标签: timescaledb