2024-07-17 09:49:15 +00:00
|
|
|
-- Tags: no-random-settings, no-object-storage
|
2024-07-03 07:27:44 +00:00
|
|
|
|
2024-07-02 15:08:14 +00:00
|
|
|
SET allow_experimental_dynamic_type = 1;
|
|
|
|
DROP TABLE IF EXISTS test_dynamic;
|
|
|
|
CREATE TABLE test_dynamic (id UInt64, d Dynamic) ENGINE = MergeTree ORDER BY id SETTINGS min_bytes_for_wide_part = 0;
|
|
|
|
INSERT INTO test_dynamic VALUES (1, 'foo'), (2, 1111), (3, [1, 2, 3]);
|
2024-07-03 16:37:01 +00:00
|
|
|
EXPLAIN QUERY TREE SELECT d.String FROM test_dynamic SETTINGS allow_experimental_analyzer = 1;
|
2024-07-02 15:08:14 +00:00
|
|
|
SYSTEM DROP MARK CACHE;
|
|
|
|
SELECT d.String FROM test_dynamic SETTINGS allow_experimental_analyzer = 1;
|
|
|
|
SYSTEM DROP MARK CACHE;
|
|
|
|
SELECT d.String FROM test_dynamic SETTINGS allow_experimental_analyzer = 0;
|
|
|
|
SYSTEM FLUSH LOGS;
|
|
|
|
SELECT
|
|
|
|
ProfileEvents['FileOpen']
|
|
|
|
FROM system.query_log
|
|
|
|
WHERE (type = 2) AND (query LIKE 'SELECT d.String %test_dynamic%') AND (current_database = currentDatabase())
|
|
|
|
ORDER BY event_time_microseconds DESC
|
|
|
|
LIMIT 2;
|
|
|
|
|
|
|
|
DROP TABLE test_dynamic;
|
|
|
|
|