From 8a81946033eac461c155f388fa1595f8e42db794 Mon Sep 17 00:00:00 2001 From: MikhailBurdukov Date: Wed, 17 Jul 2024 10:52:01 +0000 Subject: [PATCH] Rename opt --- src/Core/Settings.h | 3 +-- src/Core/SettingsChangesHistory.cpp | 2 +- src/Storages/StorageDictionary.cpp | 2 +- .../0_stateless/03198_dictionary_validate_primary_key_type.sql | 2 +- 4 files changed, 4 insertions(+), 5 deletions(-) diff --git a/src/Core/Settings.h b/src/Core/Settings.h index c116c888f28..9d2e3606e67 100644 --- a/src/Core/Settings.h +++ b/src/Core/Settings.h @@ -151,8 +151,7 @@ class IColumn; M(UInt64, max_local_write_bandwidth, 0, "The maximum speed of local writes in bytes per second.", 0) \ M(Bool, stream_like_engine_allow_direct_select, false, "Allow direct SELECT query for Kafka, RabbitMQ, FileLog, Redis Streams, and NATS engines. In case there are attached materialized views, SELECT query is not allowed even if this setting is enabled.", 0) \ M(String, stream_like_engine_insert_queue, "", "When stream like engine reads from multiple queues, user will need to select one queue to insert into when writing. Used by Redis Streams and NATS.", 0) \ - M(Bool, dictionary_validate_id_type, false, "Validate primary key type for dictionaries. By default id type for simple layouts will be implicitly converted to UInt64.", 0) \ - \ + M(Bool, dictionary_validate_primary_key_type, false, "Validate primary key type for dictionaries. By default id type for simple layouts will be implicitly converted to UInt64.", 0) \ M(Bool, distributed_insert_skip_read_only_replicas, false, "If true, INSERT into Distributed will skip read-only replicas.", 0) \ M(Bool, distributed_foreground_insert, false, "If setting is enabled, insert query into distributed waits until data are sent to all nodes in a cluster. \n\nEnables or disables synchronous data insertion into a `Distributed` table.\n\nBy default, when inserting data into a Distributed table, the ClickHouse server sends data to cluster nodes in the background. When `distributed_foreground_insert` = 1, the data is processed synchronously, and the `INSERT` operation succeeds only after all the data is saved on all shards (at least one replica for each shard if `internal_replication` is true).", 0) ALIAS(insert_distributed_sync) \ M(UInt64, distributed_background_insert_timeout, 0, "Timeout for insert query into distributed. Setting is used only with insert_distributed_sync enabled. Zero value means no timeout.", 0) ALIAS(insert_distributed_timeout) \ diff --git a/src/Core/SettingsChangesHistory.cpp b/src/Core/SettingsChangesHistory.cpp index 4e9e402f1d4..b2669a0e1c5 100644 --- a/src/Core/SettingsChangesHistory.cpp +++ b/src/Core/SettingsChangesHistory.cpp @@ -67,7 +67,7 @@ static std::initializer_listgetSettingsRef().dictionary_validate_id_type)}, comment, location_, context_) + table_id_, dictionary_name_, ColumnsDescription{getNamesAndTypes(dictionary_structure_, context_->getSettingsRef().dictionary_validate_primary_key_type)}, comment, location_, context_) { } diff --git a/tests/queries/0_stateless/03198_dictionary_validate_primary_key_type.sql b/tests/queries/0_stateless/03198_dictionary_validate_primary_key_type.sql index eaf51ef7ead..e7b8730abbd 100644 --- a/tests/queries/0_stateless/03198_dictionary_validate_primary_key_type.sql +++ b/tests/queries/0_stateless/03198_dictionary_validate_primary_key_type.sql @@ -7,7 +7,7 @@ SOURCE(CLICKHOUSE(HOST 'localhost' PORT 9000 DB 'test_db' TABLE 'table_01' USER LIFETIME(MIN 1 MAX 10) LAYOUT(FLAT()); -SET dictionary_validate_id_type=1; +SET dictionary_validate_primary_key_type=1; CREATE DICTIONARY `test_dictionary1` ( `n1` String,