Clickhouse: do not display INFORMATION_SCHEMA tables (#7489)

As with other query runners, do not show system tables in the schema list.
This commit is contained in:
Eric Radman
2025-07-31 08:07:40 -04:00
committed by GitHub
parent f5e2a4c0fc
commit 09ed3c4b81

View File

@@ -77,7 +77,11 @@ class ClickHouse(BaseSQLQueryRunner):
self._url = self._url._replace(netloc="{}:{}".format(self._url.hostname, port))
def _get_tables(self, schema):
query = "SELECT database, table, name FROM system.columns WHERE database NOT IN ('system')"
query = """
SELECT database, table, name
FROM system.columns
WHERE database NOT IN ('system', 'information_schema', 'INFORMATION_SCHEMA')
"""
results, error = self.run_query(query, None)