diff --git a/be/src/vec/functions/function_encryption.cpp b/be/src/vec/functions/function_encryption.cpp index 32eeb5b2cfc6d9..f63e9bca1b0937 100644 --- a/be/src/vec/functions/function_encryption.cpp +++ b/be/src/vec/functions/function_encryption.cpp @@ -335,7 +335,7 @@ struct EncryptionAndDecryptFourImpl { return Status::OK(); } - static void vector_const(const ColumnString* column, StringRef iv_arg, StringRef key_arg, + static void vector_const(const ColumnString* column, StringRef key_arg, StringRef iv_arg, StringRef mode_arg, size_t input_rows_count, ColumnString::Chars& result_data, ColumnString::Offsets& result_offset, NullMap& null_map) { diff --git a/regression-test/data/query_p0/sql_functions/encryption_digest/test_encryption_function.out b/regression-test/data/query_p0/sql_functions/encryption_digest/test_encryption_function.out index c260c12470add8..9e920596f894cf 100644 --- a/regression-test/data/query_p0/sql_functions/encryption_digest/test_encryption_function.out +++ b/regression-test/data/query_p0/sql_functions/encryption_digest/test_encryption_function.out @@ -137,3 +137,6 @@ text -- !sql -- 82ec580fe6d36ae4f81cae3c73f4a5b3b5a09c943172dc9053c69fd8e18dca1e +-- !sql -- +aaaaaa + diff --git a/regression-test/suites/query_p0/sql_functions/encryption_digest/test_encryption_function.groovy b/regression-test/suites/query_p0/sql_functions/encryption_digest/test_encryption_function.groovy index afa8c2c132bcf3..4b0fd3d497d420 100644 --- a/regression-test/suites/query_p0/sql_functions/encryption_digest/test_encryption_function.groovy +++ b/regression-test/suites/query_p0/sql_functions/encryption_digest/test_encryption_function.groovy @@ -132,4 +132,21 @@ suite("test_encryption_function") { qt_sql "SELECT SM3(\"abc\");" qt_sql "select sm3(\"abcd\");" qt_sql "select sm3sum(\"ab\",\"cd\");" + sql "DROP TABLE IF EXISTS quantile_table" + sql""" + CREATE TABLE quantile_table + ( + id int, + k string + ) + ENGINE=OLAP + UNIQUE KEY(id) + DISTRIBUTED BY HASH(id) BUCKETS 4 + PROPERTIES ( + "enable_unique_key_merge_on_write" = "true", + "replication_num" = "1" + ); + """ + sql""" insert into quantile_table values(1,"aaaaaa");""" + qt_sql """ select sm4_decrypt(sm4_encrypt(k,"doris","0123456789abcdef"),"doris","0123456789abcdef") from quantile_table; """ }