betodealmeida commented on a change in pull request #14252:
URL: https://github.com/apache/superset/pull/14252#discussion_r618055105



##########
File path: superset/db_engine_specs/hive.py
##########
@@ -530,7 +534,23 @@ def get_function_names(cls, database: "Database") -> 
List[str]:
         :param database: The database to get functions for
         :return: A list of function names useable in the database
         """
-        return database.get_df("SHOW FUNCTIONS")["tab_name"].tolist()
+        df = database.get_df("SHOW FUNCTIONS")
+        if cls._show_functions_column in df:
+            return df[cls._show_functions_column].tolist()
+
+        columns = df.columns.values.tolist()
+        logger.error(

Review comment:
       In this case I wanted to log here where we have more context, so that we 
can quickly fix the problem when we see it in the logs. Also, even if the 
result is not as expected we can still try our best and use the results if they 
have a single column.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to