2021-09-12 12:35:27 +00:00
|
|
|
-- Tags: no-parallel
|
|
|
|
|
2020-09-15 09:16:48 +00:00
|
|
|
DROP TABLE IF EXISTS set;
|
2020-09-18 12:48:55 +00:00
|
|
|
DROP TABLE IF EXISTS number;
|
2020-09-15 09:16:48 +00:00
|
|
|
|
2020-09-18 12:48:55 +00:00
|
|
|
CREATE TABLE number (number UInt64) ENGINE = Memory();
|
|
|
|
INSERT INTO number values (1);
|
2020-09-15 09:16:48 +00:00
|
|
|
|
2020-09-18 12:48:55 +00:00
|
|
|
SELECT '----- Default Settings -----';
|
|
|
|
CREATE TABLE set (val UInt64) ENGINE = Set();
|
|
|
|
INSERT INTO set VALUES (1);
|
2020-09-15 09:16:48 +00:00
|
|
|
DETACH TABLE set;
|
2020-09-19 16:39:24 +00:00
|
|
|
ATTACH TABLE set;
|
2020-09-18 12:48:55 +00:00
|
|
|
SELECT number FROM number WHERE number IN set LIMIT 1;
|
2020-09-15 09:16:48 +00:00
|
|
|
|
2020-09-17 13:53:39 +00:00
|
|
|
DROP TABLE set;
|
2020-09-18 12:48:55 +00:00
|
|
|
|
2020-09-18 12:58:27 +00:00
|
|
|
SELECT '----- Settings persistent=1 -----';
|
|
|
|
CREATE TABLE set (val UInt64) ENGINE = Set() SETTINGS persistent=1;
|
2020-09-18 12:48:55 +00:00
|
|
|
INSERT INTO set VALUES (1);
|
|
|
|
DETACH TABLE set;
|
2020-09-19 16:39:24 +00:00
|
|
|
ATTACH TABLE set;
|
2020-09-18 12:48:55 +00:00
|
|
|
SELECT number FROM number WHERE number IN set LIMIT 1;
|
|
|
|
|
|
|
|
DROP TABLE set;
|
|
|
|
|
2020-09-18 12:58:27 +00:00
|
|
|
SELECT '----- Settings persistent=0 -----';
|
|
|
|
CREATE TABLE set (val UInt64) ENGINE = Set() SETTINGS persistent=0;
|
2020-09-18 12:48:55 +00:00
|
|
|
INSERT INTO set VALUES (1);
|
|
|
|
DETACH TABLE set;
|
2020-09-19 16:39:24 +00:00
|
|
|
ATTACH TABLE set;
|
2020-09-18 12:48:55 +00:00
|
|
|
SELECT number FROM number WHERE number IN set LIMIT 1;
|
|
|
|
|
|
|
|
DROP TABLE set;
|
2020-09-19 16:39:24 +00:00
|
|
|
DROP TABLE number;
|