mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-21 15:12:02 +00:00
97f2a2213e
* Move some code outside dbms/src folder * Fix paths
23 lines
600 B
SQL
23 lines
600 B
SQL
DROP TABLE IF EXISTS test_00615;
|
|
|
|
CREATE TABLE test_00615
|
|
(
|
|
dt Date,
|
|
id Int32,
|
|
key String,
|
|
data Nullable(Int8)
|
|
) ENGINE = MergeTree(dt, (id, key, dt), 8192);
|
|
|
|
INSERT INTO test_00615 (dt,id, key,data) VALUES ('2000-01-01', 100, 'key', 100500);
|
|
|
|
alter table test_00615 drop column data;
|
|
alter table test_00615 add column data Nullable(Float64);
|
|
|
|
INSERT INTO test_00615 (dt,id, key,data) VALUES ('2000-01-01', 100, 'key', 100500);
|
|
|
|
SELECT * FROM test_00615 ORDER BY data NULLS FIRST;
|
|
OPTIMIZE TABLE test_00615;
|
|
SELECT * FROM test_00615 ORDER BY data NULLS FIRST;
|
|
|
|
DROP TABLE test_00615;
|