[SPARK-56695][SQL][DML] Resolve Path Based Tables for both Reads and Writes#56039
Draft
andreaschat-db wants to merge 15 commits into
Draft
[SPARK-56695][SQL][DML] Resolve Path Based Tables for both Reads and Writes#56039andreaschat-db wants to merge 15 commits into
andreaschat-db wants to merge 15 commits into
Conversation
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.
What changes were proposed in this pull request?
This PR fixes an issue where we would only correctly resolve path based tables if they were the target of transactional writes. The DataSource catalog resolution is being moved to
CatalogAndIdentifierso it can by used for both the target of the transactional write as well as the any other tables read.Why are the changes needed?
The catalog needs to be resolved correctly for all path based tables participating in a transactional write. This includes both the target as well as any other tables read. Without this fix, any scan on path-based tables would miss the configured catalog and would fall back to the session catalog.
Furthermore, in DSv2 transactions it is important to restrict all participating tables to a single catalog. This allows the single transactional catalog to track all reads and predicates that are relevant to the transaction.
Does this PR introduce any user-facing change?
Yes. Path based tables are now correctly resolved for both read and write operations.
How was this patch tested?
Added new tests.
Was this patch authored or co-authored using generative AI tooling?
Claude Sonnet 4.6.