diff --git a/tests/queries/0_stateless/01280_ssd_complex_key_dictionary.sh b/tests/queries/0_stateless/01280_ssd_complex_key_dictionary.sh index dc2d1120c28..ff62b70c184 100755 --- a/tests/queries/0_stateless/01280_ssd_complex_key_dictionary.sh +++ b/tests/queries/0_stateless/01280_ssd_complex_key_dictionary.sh @@ -40,7 +40,7 @@ $CLICKHOUSE_CLIENT -n --query=" LIFETIME(MIN 1000 MAX 2000) LAYOUT(COMPLEX_KEY_SSD_CACHE(FILE_SIZE 8192 PATH '$USER_FILES_PATH/0d'));" -# $CLICKHOUSE_CLIENT --testmode --query="SELECT dictHas('01280_db.ssd_dict', 'a', tuple('1')); -- {ServerError 43}" +$CLICKHOUSE_CLIENT --testmode -nq "SELECT dictHas('01280_db.ssd_dict', 'a', tuple('1')); -- { serverError 43 }" $CLICKHOUSE_CLIENT -n --query=" SELECT 'TEST_SMALL'; @@ -64,7 +64,7 @@ $CLICKHOUSE_CLIENT -n --query=" SELECT dictGetInt32('01280_db.ssd_dict', 'b', tuple('10', toInt32(-20))); SELECT dictGetString('01280_db.ssd_dict', 'c', tuple('10', toInt32(-20)));" -# $CLICKHOUSE_CLIENT --testmode --query="SELECT dictGetUInt64('01280_db.ssd_dict', 'a', tuple(toInt32(3))); --{ServerError 53}" +$CLICKHOUSE_CLIENT --testmode -nq "SELECT dictGetUInt64('01280_db.ssd_dict', 'a', tuple(toInt32(3))); -- { serverError 53 }" $CLICKHOUSE_CLIENT -n --query="DROP DICTIONARY 01280_db.ssd_dict; DROP TABLE IF EXISTS 01280_db.keys_table; diff --git a/tests/queries/0_stateless/01684_ssd_cache_dictionary_simple_key.sh b/tests/queries/0_stateless/01684_ssd_cache_dictionary_simple_key.sh index 28388ae9014..3e6b5146a80 100755 --- a/tests/queries/0_stateless/01684_ssd_cache_dictionary_simple_key.sh +++ b/tests/queries/0_stateless/01684_ssd_cache_dictionary_simple_key.sh @@ -117,7 +117,7 @@ $CLICKHOUSE_CLIENT -n --query=" PRIMARY KEY id SOURCE(CLICKHOUSE(HOST 'localhost' PORT tcpPort() USER 'default' TABLE 'simple_key_hierarchy_table')) LIFETIME(MIN 1 MAX 1000) - LAYOUT(SSD_CACHE(BLOCK_SIZE 4096 FILE_SIZE 8192 PATH './user_files/2d')); + LAYOUT(SSD_CACHE(BLOCK_SIZE 4096 FILE_SIZE 8192 PATH '$USER_FILES_PATH/2d')); SELECT 'Dictionary cache_dictionary_simple_key_hierarchy'; SELECT 'dictGet'; diff --git a/tests/queries/0_stateless/01804_dictionary_decimal256_type.reference b/tests/queries/0_stateless/01804_dictionary_decimal256_type.reference index 1af9d45f72b..e9803f2f9f2 100644 --- a/tests/queries/0_stateless/01804_dictionary_decimal256_type.reference +++ b/tests/queries/0_stateless/01804_dictionary_decimal256_type.reference @@ -4,8 +4,6 @@ Hashed dictionary 5.00000 Cache dictionary 5.00000 -SSDCache dictionary -5.00000 Direct dictionary 5.00000 IPTrie dictionary diff --git a/tests/queries/0_stateless/01875_ssd_cache_dictionary_decimal256_type.reference b/tests/queries/0_stateless/01875_ssd_cache_dictionary_decimal256_type.reference new file mode 100644 index 00000000000..9b3c41ac646 --- /dev/null +++ b/tests/queries/0_stateless/01875_ssd_cache_dictionary_decimal256_type.reference @@ -0,0 +1,2 @@ +SSDCache dictionary +5.00000 diff --git a/tests/queries/0_stateless/01875_ssd_cache_dictionary_decimal256_type.sh b/tests/queries/0_stateless/01875_ssd_cache_dictionary_decimal256_type.sh new file mode 100755 index 00000000000..51c47d4ad14 --- /dev/null +++ b/tests/queries/0_stateless/01875_ssd_cache_dictionary_decimal256_type.sh @@ -0,0 +1,35 @@ +#!/usr/bin/env bash + +CURDIR=$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd) +# shellcheck source=../shell_config.sh +. "$CURDIR"/../shell_config.sh + +USER_FILES_PATH=$(clickhouse-client --query "select _path,_file from file('nonexist.txt', 'CSV', 'val1 char')" 2>&1 | grep Exception | awk '{gsub("/nonexist.txt","",$9); print $9}') + +$CLICKHOUSE_CLIENT -n --query=" + SET allow_experimental_bigint_types = 1; + + DROP TABLE IF EXISTS dictionary_decimal_source_table; + CREATE TABLE dictionary_decimal_source_table + ( + id UInt64, + decimal_value Decimal256(5) + ) ENGINE = TinyLog; + + INSERT INTO dictionary_decimal_source_table VALUES (1, 5.0); + + DROP DICTIONARY IF EXISTS ssd_cache_dictionary; + CREATE DICTIONARY ssd_cache_dictionary + ( + id UInt64, + decimal_value Decimal256(5) + ) + PRIMARY KEY id + SOURCE(CLICKHOUSE(HOST 'localhost' PORT tcpPort() TABLE 'dictionary_decimal_source_table')) + LIFETIME(MIN 1 MAX 1000) + LAYOUT(SSD_CACHE(BLOCK_SIZE 4096 FILE_SIZE 8192 PATH '$USER_FILES_PATH/0d')); + + SELECT 'SSDCache dictionary'; + SELECT dictGet('ssd_cache_dictionary', 'decimal_value', toUInt64(1)); + + DROP DICTIONARY ssd_cache_dictionary;"