forked from cockroachdb/cockroach
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
opt: fix star expansion of un-labeled tuples
Prior to this commit, there was a bug with star expansion of un-labeled tuples in which only the first column of the tuple was projected. This was happening because the name "?column?" was being passed to NewTypedColumnAccessExpr for all columns in the tuple, which made it impossible to determine that they were actually different expressions. This commit fixes the issue by ensuring that an empty column name is always passed to NewTypedColumnAccessExpr when the tuple elements are unlabeled. This signals that the tuple index should be used instead of the name. Fixes cockroachdb#48179 Release note (bug fix): Fixed a bug in which (tuple).* was only expanded to the first column in the tuple and the remaining elements were dropped.
- Loading branch information
Showing
3 changed files
with
26 additions
and
9 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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