Repository navigation
Conversation
…eng, HANA, Trino, CockroachDB and Redshift
# Conflicts: # apple/Packages/TableProOracle/Sources/TableProOracleCore/OracleSchemaQueries.swift
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
CatalogTableListing. With no all-schema answer from the driver it went straight to one query per schema. It now lists the schemas, drops the system ones, and asksfetchTables(inSchemas:)once. Per schema only when the driver has no set read, or the set read fails for a reason other than a lost connection.fetchTables(inSchemas:)on Oracle, Dameng, SAP HANA, Trino, CockroachDB and Redshift: the per-schema query widened toIN (...), schema projected on every row. Oracle and Dameng split at 1,000 names (ORA-01795). Redshift still adds external tables per external schema. Trino falls back to per-schema materialized-view reads when the combined one fails.x'́) was left undoubled: PostgreSQL 17 rejects that listing with a syntax error, and in a set read one such schema name would fail every schema.apple/scripts/probes/build-large-catalog-fixtures.shbuilds the Measure the sidebar, Open Quickly and autocomplete on 100 schemas and 50,000 tables #3661 fixtures: PostgreSQL 100 schemas x 500 tables, Oracle the same in agvenzl/oracle-freecontainer, MySQL one database of 50,000 tables.TableProTrinoCoreTeststarget in TableProCore.Server time for the other schemas' tables on the PostgreSQL fixture, PostgreSQL 17.11 local, information_schema query CockroachDB and Redshift use, 3 runs on a loaded machine:
Test plan
CatalogTableListingTests: every schema through the set read (schema list, then one read with the excluded schemas left out); a failed set read falls back per schema and names only the failing schema; a lost connection in the set read fails the listing without per-schema reads.TableProOracleCoreTests(swift test): 47/47 pass, including the set query, the 1,000-name split, the owner column, the combining-mark escape and SYS qualification of the new query.TableProTrinoCoreTests(swift test): 3/3 pass.PostgreSQLDriverTests: Cockroach and Redshift set queries and rows, combining-mark quoting; new builders added to the literal-quoting matrix.swiftc -typecheckof the PostgreSQL, Oracle, Trino, HANA and Dameng plugin sources and the changed PostgreSQL tests passed. CI covers the rest.Not in this PR
FROMandschema.; resident memory) and their budgets. They need a quiet machine and the three fixtures.SHOW OBJECTS IN DATABASEcaps at 10,000 rows (same reason as feat(plugins): list every schema's tables in one query on SQL Server and DuckDB #3096).INFO FOR DBper database), R2 SQL (SHOW TABLESper namespace) have no single catalog read. Spanner could take one but needs a live instance for its two dialects.Docs: TableProApp/docs#67
Refs #3661