From f21ba79fd81926ae2a612f0b69942e51ae37127d Mon Sep 17 00:00:00 2001 From: Vasily Nemkov Date: Mon, 25 Sep 2023 17:25:43 +0200 Subject: [PATCH 1/2] Set backward_compatibility_lowcardinality_as_wrapped_column default value to false --- clickhouse/client.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/clickhouse/client.h b/clickhouse/client.h index a66d59a6..35000784 100644 --- a/clickhouse/client.h +++ b/clickhouse/client.h @@ -123,7 +123,7 @@ struct ClientOptions { * @see LowCardinalitySerializationAdaptor, CreateColumnByType */ [[deprecated("Makes implementation of LC(X) harder and code uglier. Will be removed in next major release (3.0) ")]] - DECLARE_FIELD(backward_compatibility_lowcardinality_as_wrapped_column, bool, SetBakcwardCompatibilityFeatureLowCardinalityAsWrappedColumn, true); + DECLARE_FIELD(backward_compatibility_lowcardinality_as_wrapped_column, bool, SetBakcwardCompatibilityFeatureLowCardinalityAsWrappedColumn, false); /** Set max size data to compress if compression enabled. * From 9b2b2190508657743b5948f0bda9839679e6e47e Mon Sep 17 00:00:00 2001 From: Vasily Nemkov Date: Tue, 26 Sep 2023 12:33:36 +0200 Subject: [PATCH 2/2] Fixed the tests --- ut/low_cardinality_nullable_tests.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/ut/low_cardinality_nullable_tests.cpp b/ut/low_cardinality_nullable_tests.cpp index 8918f251..357f28a9 100644 --- a/ut/low_cardinality_nullable_tests.cpp +++ b/ut/low_cardinality_nullable_tests.cpp @@ -122,8 +122,8 @@ TEST(LowCardinalityOfNullable, InsertAndQueryEmpty) { block.AppendColumn("words", column); Client client(ClientOptions(localHostEndpoint) - .SetBakcwardCompatibilityFeatureLowCardinalityAsWrappedColumn(false) - .SetPingBeforeQuery(true)); + .SetBakcwardCompatibilityFeatureLowCardinalityAsWrappedColumn(false) + .SetPingBeforeQuery(true)); createTable(client); @@ -141,7 +141,8 @@ TEST(LowCardinalityOfNullable, ThrowOnBackwardsCompatibleLCColumn) { block.AppendColumn("words", column); Client client(ClientOptions(localHostEndpoint) - .SetPingBeforeQuery(true)); + .SetPingBeforeQuery(true) + .SetBakcwardCompatibilityFeatureLowCardinalityAsWrappedColumn(true)); createTable(client);