mirror of
https://github.com/hanzo-ds/sqlparser.git
synced 2026-10-30 20:53:50 +00:00
13 lines
413 B
SQL
13 lines
413 B
SQL
CREATE TABLE IF NOT EXISTS test.events_local UUID '1234' ON CLUSTER 'default_cluster' (
|
|
f0 String,
|
|
f1 String,
|
|
f2 String,
|
|
f3 Datetime,
|
|
f4 Datetime,
|
|
f5 Map(String,String),
|
|
f6 String,
|
|
f7 Datetime DEFAULT now()
|
|
) ENGINE = ReplicatedMergeTree('/clickhouse/tables/{layer}-{shard}/test/events_local', '{replica}')
|
|
TTL f3 + INTERVAL 6 MONTH
|
|
PARTITION BY toYYYYMMDD(f3)
|
|
ORDER BY (f0,f1,f2); |