You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
DuckDB: tables in non-main schemas are invisible (no sidebar listing, no schema switcher) #2131
For DuckDB connections, tables that live in any schema other than main never appear anywhere in the UI — no sidebar entry, no schema picker. A database whose base tables are in custom schemas (e.g. core.bars, meta.bar_series) looks almost empty in TablePro; only the main schema's objects are listed.
The data is still reachable by typing SELECT * FROM core.bars in the SQL editor, so this is purely a navigation/visibility gap.
Steps to reproduce
Create a DuckDB file:
CREATESCHEMAcore;
CREATESCHEMAmeta;
CREATETABLEcore.bars (i INTEGER);
CREATETABLEmeta.bar_series (i INTEGER);
CREATETABLEmain.something (i INTEGER);
Open the file in TablePro.
The sidebar shows only something. core.bars and meta.bar_series are not listed, and there is no schema switcher to reach them.
Expected behavior
All schemas listed (like the PostgreSQL tree), or at least a schema picker so non-main tables can be browsed.
Where it seems to go wrong
The plugin and the app-level registry disagree about whether DuckDB has schemas:
Plugins/DuckDBDriverPlugin/DuckDBPlugin.swift fully implements multi-schema support: it declares the .multiSchema capability, and implements fetchSchemas() / switchSchema(to:).
But the registry snapshot in TablePro/Core/Plugins/PluginMetadataRegistry+RegistryDefaults.swift registers DuckDB with supportsSchemaSwitching: false and databaseGroupingStrategy: .flat.
SchemaService trusts the registry flag: it drops the schema list (if !supportsSchemas { schemasInOrder.removeValue(...) }) and loads tables via fetchTables() with no schema argument.
The plugin then resolves the nil schema to its default current schema, hardcoded to "main" (_currentSchema = "main"), and lists only information_schema.tables WHERE table_schema = 'main'.
So the plugin's fetchSchemas()/switchSchema() are dead code, and everything outside main is invisible. Flipping supportsSchemaSwitching to true (or grouping hierarchically like PostgreSQL) would surface them.
Activity
fix(plugin-duckdb): browse schemas and attached databases in the side…
fix(plugin-duckdb): browse schemas and attached databases in the side…