ClickHouse/tests/queries/0_stateless/01686_rocksdb.sql

27 lines
868 B
MySQL
Raw Normal View History

2021-06-02 15:55:20 +00:00
DROP TABLE IF EXISTS 01686_test;
2021-06-02 15:55:20 +00:00
CREATE TABLE 01686_test (key UInt64, value String) Engine=EmbeddedRocksDB PRIMARY KEY(key);
2021-06-02 15:55:20 +00:00
INSERT INTO 01686_test SELECT number, format('Hello, world ({})', toString(number)) FROM numbers(10000);
2021-06-02 15:55:20 +00:00
SELECT * FROM 01686_test WHERE key = 123;
SELECT '--';
2021-06-02 15:55:20 +00:00
SELECT * FROM 01686_test WHERE key = -123;
SELECT '--';
2021-06-02 15:55:20 +00:00
SELECT * FROM 01686_test WHERE key = 123 OR key = 4567 ORDER BY key;
SELECT '--';
2021-06-02 15:55:20 +00:00
SELECT * FROM 01686_test WHERE key = NULL;
SELECT '--';
2021-06-02 15:55:20 +00:00
SELECT * FROM 01686_test WHERE key = NULL OR key = 0;
SELECT '--';
2021-06-02 15:55:20 +00:00
SELECT * FROM 01686_test WHERE key IN (123, 456, -123) ORDER BY key;
SELECT '--';
2021-06-02 15:55:20 +00:00
SELECT * FROM 01686_test WHERE key = 'Hello'; -- { serverError 53 }
2021-06-02 15:55:20 +00:00
DETACH TABLE 01686_test NO DELAY;
ATTACH TABLE 01686_test;
2021-06-02 15:55:20 +00:00
SELECT * FROM 01686_test WHERE key IN (99, 999, 9999, -123) ORDER BY key;
2021-06-02 15:55:20 +00:00
DROP TABLE IF EXISTS 01686_test;