Conversation
…he#56802) ### What problem does this PR solve? This change extends the `tableAlias` feature from the logical plan layer to the physical plan layer, enabling table aliases to be preserved throughout the entire query execution pipeline from SQL parsing to physical execution. When analyzing query execution plans, especially for complex queries where the same table appears multiple times with different aliases, it has been challenging to match scan nodes in the plan back to their corresponding table references in the original SQL.
…utputs The 3-way merge of the upstream updated baselines missed the alias for a few suites; regenerate them from the actual output of branch-4.2 + apache#56802.
Contributor
|
Thank you for your contribution to Apache Doris. Please clearly describe your PR:
|
Contributor
Author
|
run buildall |
Contributor
FE Regression Coverage ReportIncrement line coverage |
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.
Cherry-pick of #56802 to branch-4.2
feat add table alias for catalog relation
The alias is threaded through branch-4.2's constructors, which carry extra
parameters that master does not have (cachedSlots / relationSchema /
relationSnapshot / partitionPrunablePredicates / scoreLimit / scoreRangeInfo /
annOrderKeys / annLimit); those are preserved and
tableAliasis appended last.PhysicalOlapScan keeps branch-4.2's
PhysicalOlapScan[<id>] table=...title and addsalias=...as upstream does.Expected-output baselines: the plan strings now contain
alias=...; the shape_checktpcds/tpch suites touched by this PR were verified against the branch-4.2 cluster and
the few that still lacked the alias were regenerated with -forceGenOut.
Tests: RewriteTopDownJobTest passes; shape_check tpcds_sf100 (112 suites),
tpcds_sf1000 (53), tpcds_sf10t_orc (26), tpch_sf1000 (14) and 14 nereids_rules_p0
suites + query_p0/join pass with 0 failures.