支持创建分区表时将默认分区中属于新分区的数据转移到新的分区表中
最近更新时间: 2025-02-18 16:02:00
postgres=# CREATE TABLE t_native_range_default PARTITION OF t_native_range DEFAULT;
CREATE TABLE
postgres=# insert into t_native_range values(2,'2017-08-01',2);
INSERT 0 1
postgres=# select * from t_native_range_default;
f1 | f2 | f3
----+---------------------+----
2 | 2017-08-01 00:00:00 | 2
(1 row)
postgres=# create table t_native_range_201708 partition of t_native_range for values from ('2017-08-01') to ('2017-09-01');
CREATE TABLE
postgres=# select * from t_native_range_201708;
f1 | f2 | f3
----+---------------------+----
2 | 2017-08-01 00:00:00 | 2
(1 row)
postgres=# select * from t_native_range_default;
f1 | f2 | f3
----+----+----
(0 rows)
postgres=#
TDSQ了PG实例自动转换。