Commit adf009d
[SPARK-44610][SQL] DeduplicateRelations should retain Alias metadata when creating a new instance
### What changes were proposed in this pull request?
This fixes a small but obvious mistake in the rule `DeduplicateRelations`. When creating a new instance of an existing Alias, we should only make it have a new exprId, and retain everything else, including metadata.
### Why are the changes needed?
To fix a potential bug. I can't found any end-to-end query that is affected by this bug, but it's wrong to lose the metadata.
### Does this PR introduce _any_ user-facing change?
No
### How was this patch tested?
existing tests
Closes apache#42242 from cloud-fan/mm.
Authored-by: Wenchen Fan <[email protected]>
Signed-off-by: Gengliang Wang <[email protected]>1 parent 1380a3d commit adf009d
File tree
1 file changed
+1
-1
lines changed- sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/analysis
1 file changed
+1
-1
lines changedLines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
429 | 429 | | |
430 | 430 | | |
431 | 431 | | |
432 | | - | |
| 432 | + | |
433 | 433 | | |
434 | 434 | | |
435 | 435 | | |
| |||
0 commit comments