Skip to content

Conversation

@mihailotim-db
Copy link
Contributor

What changes were proposed in this pull request?

Improve NormalizePlan by fixing normalization of InheritAnalysisRules and add normalization for CommonExpressionId and expressions that use it.

Why are the changes needed?

PR #49460 mishandled normalization of RuntimeReplaceable because it copied original expression's tags to the replacement. This PR fixes that.

Does this PR introduce any user-facing change?

No

How was this patch tested?

Added a test case to NormalizePlanSuite.

Was this patch authored or co-authored using generative AI tooling?

No

@github-actions github-actions bot added the SQL label Jan 21, 2025
@cloud-fan
Copy link
Contributor

thanks, merging to master/4.0!

@cloud-fan cloud-fan closed this in 09cb059 Jan 22, 2025
cloud-fan pushed a commit that referenced this pull request Jan 22, 2025
### What changes were proposed in this pull request?
Improve `NormalizePlan` by fixing normalization of `InheritAnalysisRules` and add normalization for `CommonExpressionId` and expressions that use it.

### Why are the changes needed?

PR #49460 mishandled normalization of `RuntimeReplaceable` because it copied original expression's tags to the replacement. This PR fixes that.

### Does this PR introduce _any_ user-facing change?
No

### How was this patch tested?
Added a test case to `NormalizePlanSuite`.

### Was this patch authored or co-authored using generative AI tooling?
No

Closes #49585 from mihailotim-db/mihailotim-db/normalize_plan_followup.

Authored-by: Mihailo Timotic <mihailo.timotic@databricks.com>
Signed-off-by: Wenchen Fan <wenchen@databricks.com>
(cherry picked from commit 09cb059)
Signed-off-by: Wenchen Fan <wenchen@databricks.com>
zifeif2 pushed a commit to zifeif2/spark that referenced this pull request Nov 14, 2025
### What changes were proposed in this pull request?
Improve `NormalizePlan` by fixing normalization of `InheritAnalysisRules` and add normalization for `CommonExpressionId` and expressions that use it.

### Why are the changes needed?

PR apache#49460 mishandled normalization of `RuntimeReplaceable` because it copied original expression's tags to the replacement. This PR fixes that.

### Does this PR introduce _any_ user-facing change?
No

### How was this patch tested?
Added a test case to `NormalizePlanSuite`.

### Was this patch authored or co-authored using generative AI tooling?
No

Closes apache#49585 from mihailotim-db/mihailotim-db/normalize_plan_followup.

Authored-by: Mihailo Timotic <mihailo.timotic@databricks.com>
Signed-off-by: Wenchen Fan <wenchen@databricks.com>
(cherry picked from commit e9f1344)
Signed-off-by: Wenchen Fan <wenchen@databricks.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants