Explorar o código

HUE-2723 [hive] Listing table information in non default DB fails

Romain Rigaux %!s(int64=10) %!d(string=hai) anos
pai
achega
6e55578
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      apps/beeswax/src/beeswax/server/hive_server2_lib.py

+ 1 - 1
apps/beeswax/src/beeswax/server/hive_server2_lib.py

@@ -589,7 +589,7 @@ class HiveServerClient:
     table_results, table_schema = self.fetch_result(res.operationHandle, orientation=TFetchOrientation.FETCH_NEXT)
     table_results, table_schema = self.fetch_result(res.operationHandle, orientation=TFetchOrientation.FETCH_NEXT)
     self.close_operation(res.operationHandle)
     self.close_operation(res.operationHandle)
 
 
-    query = 'DESCRIBE FORMATTED %s' % table_name
+    query = 'DESCRIBE FORMATTED %s.%s' % (database, table_name)
     (desc_results, desc_schema), operation_handle = self.execute_statement(query, max_rows=5000, orientation=TFetchOrientation.FETCH_NEXT)
     (desc_results, desc_schema), operation_handle = self.execute_statement(query, max_rows=5000, orientation=TFetchOrientation.FETCH_NEXT)
     self.close_operation(operation_handle)
     self.close_operation(operation_handle)