Skip to content

Commit

Permalink
colbuilder: address a minor nit in a recent fix
Browse files Browse the repository at this point in the history
In 7ad29c3 we made some changes about
how argument to window functions are being cast to the same type in some
cases. After the cast we now update the column index but forgot to
update the type to the new one. However, this doesn't lead to problems
since `argTypes` is only used by the aggregate window functions, and the
casts can only be needed for non-aggregate window functions. Still, it's
better to update the types to avoid confusion.

Release note: None
  • Loading branch information
yuzefovich committed May 24, 2022
1 parent c03f7a0 commit 9223ca1
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions pkg/sql/colexec/colbuilder/execplan.go
Original file line number Diff line number Diff line change
Expand Up @@ -1237,6 +1237,7 @@ func NewColOperator(
}
typs = append(typs, typ)
argIdxs[i] = castIdx
argTypes[i] = typ
}

partitionColIdx := tree.NoColumnIdx
Expand Down

0 comments on commit 9223ca1

Please sign in to comment.