mirror of
https://github.com/GreptimeTeam/greptimedb.git
synced 2026-01-08 22:32:55 +00:00
* feat: update physical table schema on alter * feat: alter logical table in sql path * feat: invalidate cache step1 * feat: invalidate cache step2 * feat: invalidate cache step3 * feat: invalidate cache step4 * fix: failed ut * fix: standalone cache invalidator * feat: log the count of already finished * feat: re-invalidate cache * chore: by comment * chore: Update src/common/meta/src/ddl/create_logical_tables.rs --------- Co-authored-by: Yingwen <realevenyag@gmail.com>
30 lines
628 B
SQL
30 lines
628 B
SQL
CREATE TABLE phy (ts timestamp time index, val double) engine=metric with ("physical_metric_table" = "");
|
|
|
|
SHOW TABLES;
|
|
|
|
CREATE TABLE t1 (ts timestamp time index, val double, host string primary key) engine = metric with ("on_physical_table" = "phy");
|
|
|
|
CREATE TABLE t2 (ts timestamp time index, job string primary key, val double) engine = metric with ("on_physical_table" = "phy");
|
|
|
|
DESC TABLE t1;
|
|
|
|
DESC TABLE t2;
|
|
|
|
DESC TABLE phy;
|
|
|
|
ALTER TABLE t1 ADD COLUMN k STRING PRIMARY KEY;
|
|
|
|
ALTER TABLE t2 ADD COLUMN k STRING PRIMARY KEY;
|
|
|
|
DESC TABLE t1;
|
|
|
|
DESC TABLE t2;
|
|
|
|
DESC TABLE phy;
|
|
|
|
DROP TABLE t1;
|
|
|
|
DROP TABLE t2;
|
|
|
|
DROP TABLE phy;
|