mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-30 11:32:03 +00:00
97f2a2213e
* Move some code outside dbms/src folder * Fix paths
35 lines
1.9 KiB
SQL
35 lines
1.9 KiB
SQL
DROP TABLE IF EXISTS multidimensional;
|
|
CREATE TABLE multidimensional (x UInt64, arr Array(Array(String))) ENGINE = MergeTree ORDER BY x;
|
|
|
|
INSERT INTO multidimensional VALUES (1, [['Hello', 'World'], ['Goodbye'], []]);
|
|
SELECT * FROM multidimensional;
|
|
|
|
ALTER TABLE multidimensional ADD COLUMN t Tuple(String, Array(Nullable(String)), Tuple(UInt32, Date));
|
|
INSERT INTO multidimensional (t) VALUES (('Hello', ['World', NULL], (123, '2000-01-01')));
|
|
SELECT * FROM multidimensional ORDER BY t;
|
|
|
|
OPTIMIZE TABLE multidimensional;
|
|
SELECT * FROM multidimensional ORDER BY t;
|
|
|
|
DROP TABLE multidimensional;
|
|
|
|
CREATE TABLE multidimensional (x UInt64, arr Array(Array(String)), t Tuple(String, Array(Nullable(String)), Tuple(UInt32, Date))) ENGINE = Memory;
|
|
INSERT INTO multidimensional VALUES (1, [['Hello', 'World'], ['Goodbye'], []], ('Hello', ['World', NULL], (123, '2000-01-01')));
|
|
SELECT * FROM multidimensional ORDER BY t;
|
|
DROP TABLE multidimensional;
|
|
|
|
CREATE TABLE multidimensional (x UInt64, arr Array(Array(String)), t Tuple(String, Array(Nullable(String)), Tuple(UInt32, Date))) ENGINE = TinyLog;
|
|
INSERT INTO multidimensional VALUES (1, [['Hello', 'World'], ['Goodbye'], []], ('Hello', ['World', NULL], (123, '2000-01-01')));
|
|
SELECT * FROM multidimensional ORDER BY t;
|
|
DROP TABLE multidimensional;
|
|
|
|
CREATE TABLE multidimensional (x UInt64, arr Array(Array(String)), t Tuple(String, Array(Nullable(String)), Tuple(UInt32, Date))) ENGINE = StripeLog;
|
|
INSERT INTO multidimensional VALUES (1, [['Hello', 'World'], ['Goodbye'], []], ('Hello', ['World', NULL], (123, '2000-01-01')));
|
|
SELECT * FROM multidimensional ORDER BY t;
|
|
DROP TABLE multidimensional;
|
|
|
|
CREATE TABLE multidimensional (x UInt64, arr Array(Array(String)), t Tuple(String, Array(Nullable(String)), Tuple(UInt32, Date))) ENGINE = Log;
|
|
INSERT INTO multidimensional VALUES (1, [['Hello', 'World'], ['Goodbye'], []], ('Hello', ['World', NULL], (123, '2000-01-01')));
|
|
SELECT * FROM multidimensional ORDER BY t;
|
|
DROP TABLE multidimensional;
|