From 2a2e4c212391d2f5a2b8ea64d77de9cb821e4e7a Mon Sep 17 00:00:00 2001 From: Octavian Ciubotaru Date: Fri, 14 Feb 2025 10:30:32 +0800 Subject: [PATCH] [KYUUBI #6905] PyHive HTTP/HTTPS dialect to use the database name from url ### Why are the changes needed? HTTP dialect ignores the database specified in the URL and uses the "default" instead. ### How was this patch tested? Tested manually. ### Was this patch authored or co-authored using generative AI tooling? No. Closes #6906 from developster/pyhive-update1. Closes #6905 6e21d7259 [Cheng Pan] Update python/pyhive/sqlalchemy_hive.py ec7d4629e [Octavian Ciubotaru] [KYUUBI #6905] PyHive HTTP/HTTPS dialect to use the database name from url Lead-authored-by: Octavian Ciubotaru Co-authored-by: Cheng Pan Signed-off-by: Cheng Pan --- python/pyhive/sqlalchemy_hive.py | 1 + 1 file changed, 1 insertion(+) diff --git a/python/pyhive/sqlalchemy_hive.py b/python/pyhive/sqlalchemy_hive.py index 355f296da..66f7d75cc 100644 --- a/python/pyhive/sqlalchemy_hive.py +++ b/python/pyhive/sqlalchemy_hive.py @@ -421,6 +421,7 @@ class HiveHTTPDialect(HiveDialect): "scheme": self.scheme, "username": url.username or None, "password": url.password or None, + "database": url.database or "default", } if url.query: kwargs.update(url.query)