1
0
Fork 0

Merging upstream version 17.11.0.

Signed-off-by: Daniel Baumann <daniel@debian.org>
This commit is contained in:
Daniel Baumann 2025-02-13 20:51:40 +01:00
parent 2bd548fc43
commit 14ca349bca
Signed by: daniel
GPG key ID: FBB4F0E80A80222F
69 changed files with 30974 additions and 30030 deletions

View file

@ -583,6 +583,38 @@ class TestDuckDB(Validator):
write={"duckdb": "SELECT a, BOOL_OR(b) FROM table GROUP BY a"},
)
def test_encode_decode(self):
self.validate_all(
"ENCODE(x)",
read={
"spark": "ENCODE(x, 'utf-8')",
"presto": "TO_UTF8(x)",
},
write={
"duckdb": "ENCODE(x)",
"spark": "ENCODE(x, 'utf-8')",
"presto": "TO_UTF8(x)",
},
)
self.validate_all(
"DECODE(x)",
read={
"spark": "DECODE(x, 'utf-8')",
"presto": "FROM_UTF8(x)",
},
write={
"duckdb": "DECODE(x)",
"spark": "DECODE(x, 'utf-8')",
"presto": "FROM_UTF8(x)",
},
)
self.validate_all(
"DECODE(x)",
read={
"presto": "FROM_UTF8(x, y)",
},
)
def test_rename_table(self):
self.validate_all(
"ALTER TABLE db.t1 RENAME TO db.t2",