From 146edca4f76627c9f5b13312216bf23e58fe89e2 Mon Sep 17 00:00:00 2001 From: Salvatore Mesoraca Date: Wed, 11 Sep 2024 15:35:48 +0200 Subject: [PATCH] Add tests for SHOW COLUMNS from tables with dots --- .../0_stateless/02706_show_columns.reference | 4 ++++ tests/queries/0_stateless/02706_show_columns.sql | 15 +++++++++++++++ 2 files changed, 19 insertions(+) diff --git a/tests/queries/0_stateless/02706_show_columns.reference b/tests/queries/0_stateless/02706_show_columns.reference index 29e5329d63d..32cae685a59 100644 --- a/tests/queries/0_stateless/02706_show_columns.reference +++ b/tests/queries/0_stateless/02706_show_columns.reference @@ -45,3 +45,7 @@ uint64 UInt64 NO PRI SOR \N int32 Int32 NO \N str String NO \N uint64 UInt64 NO PRI SOR \N +--- SHOW COLUMNS FROM table with dots +int32 Nullable(Int32) YES \N +str String NO SOR \N +uint64 UInt64 NO PRI SOR \N diff --git a/tests/queries/0_stateless/02706_show_columns.sql b/tests/queries/0_stateless/02706_show_columns.sql index b1a907c5c71..a5164ce8022 100644 --- a/tests/queries/0_stateless/02706_show_columns.sql +++ b/tests/queries/0_stateless/02706_show_columns.sql @@ -90,3 +90,18 @@ SHOW COLUMNS FROM database_123456789abcde.tab; DROP DATABASE database_123456789abcde; DROP TABLE tab; + +DROP TABLE IF EXISTS `tab.with.dots`; +CREATE TABLE `tab.with.dots` +( + `uint64` UInt64, + `int32` Nullable(Int32) COMMENT 'example comment', + `str` String, + INDEX idx str TYPE set(1000) +) +ENGINE = MergeTree +PRIMARY KEY (uint64) +ORDER BY (uint64, str); +SELECT '--- SHOW COLUMNS FROM table with dots'; +SHOW COLUMNS FROM `tab.with.dots`; +DROP TABLE `tab.with.dots`;