Skip to content

Commit 09bffcc

Browse files
Merge pull request #2 from stackql/bugfix/table-print
table-print-keyowrds
2 parents 737147a + 0918350 commit 09bffcc

File tree

1 file changed

+3
-12
lines changed

1 file changed

+3
-12
lines changed

go/vt/sqlparser/ast.go

Lines changed: 3 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1577,18 +1577,9 @@ func (node TableName) Format(buf *TrackedBuffer) {
15771577
if node.IsEmpty() {
15781578
return
15791579
}
1580-
buf.astPrintf(node, `"`)
1581-
if !node.QualifierThird.IsEmpty() {
1582-
buf.astPrintf(node, "%v.", node.QualifierThird)
1583-
}
1584-
if !node.QualifierSecond.IsEmpty() {
1585-
buf.astPrintf(node, "%v.", node.QualifierSecond)
1586-
}
1587-
if !node.Qualifier.IsEmpty() {
1588-
buf.astPrintf(node, "%v.", node.Qualifier)
1589-
}
1590-
buf.astPrintf(node, "%v", node.Name)
1591-
buf.astPrintf(node, `"`)
1580+
buf.WriteString(`"`)
1581+
buf.WriteString(node.GetRawVal())
1582+
buf.WriteString(`"`)
15921583
}
15931584

15941585
// Format formats the node.

0 commit comments

Comments
 (0)