You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by GitBox <gi...@apache.org> on 2022/07/20 00:22:03 UTC
[GitHub] [superset] hughhhh commented on a diff in pull request #20674: fix: Databricks views showing up as tables
hughhhh commented on code in PR #20674:
URL: https://github.com/apache/superset/pull/20674#discussion_r925057977
##########
superset/db_engine_specs/databricks.py:
##########
@@ -71,3 +76,16 @@ class DatabricksNativeEngineSpec(DatabricksODBCEngineSpec):
engine = "databricks"
engine_name = "Databricks Native Connector"
driver = "connector"
+
+ @classmethod
+ def get_table_names(
+ cls,
+ database: "Database",
+ inspector: Inspector,
+ schema: Optional[str],
+ ) -> List[str]:
+ tables = super().get_table_names(database, inspector, schema)
+ views = set(cls.get_view_names(database, inspector, schema))
+ actual_tables = set(tables) - views
Review Comment:
nit: `actual_tables = set(tables) - set(views)` for consistency
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org