Skip to content

Commit

Permalink
Fixed printing bug in AliasedExpr node (was calling wrong print metho…
Browse files Browse the repository at this point in the history
…d, which doesn't work with custom formatters)
  • Loading branch information
zachmu committed Oct 28, 2024
1 parent d14e107 commit 498dd23
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion go/vt/sqlparser/ast.go
Original file line number Diff line number Diff line change
Expand Up @@ -4303,7 +4303,7 @@ func (node *AliasedExpr) Format(buf *TrackedBuffer) {
buf.Myprintf("%v %v", node.Expr, node.As)
} else {
//buf.Myprintf("%s", node.InputExpression)
node.Expr.Format(buf)
buf.Myprintf("%v", node.Expr)
}
} else if !node.As.IsEmpty() {
buf.Myprintf("%v as %v", node.Expr, node.As)
Expand Down

0 comments on commit 498dd23

Please sign in to comment.