-
Notifications
You must be signed in to change notification settings - Fork 6k
Closed
Closed
Copy link
Labels
severity/moderatesig/sql-infraSIG: SQL InfraSIG: SQL Infratype/bugThe issue is confirmed as a bug.The issue is confirmed as a bug.
Description
Bug Report
1. Minimal reproduce step (Required)
package main
import (
"fmt"
"log"
"github.com/pingcap/tidb/pkg/parser"
"github.com/pingcap/tidb/pkg/parser/ast"
_ "github.com/pingcap/tidb/pkg/types/parser_driver"
)
func main() {
p := parser.New()
stmt, warn, err := p.ParseSQL("analyze NO_WRITE_TO_BINLOG table t")
if err != nil {
log.Fatalln(err)
}
fmt.Println(ast.GetStmtLabel(stmt[0]), warn)
}
2. What did you expect to see? (Required)
ub-3@local:~$ go run test.go
AnalyzeTable []
3. What did you see instead (Required)
ub-3@local:~$ go run test.go
2023/12/09 16:15:57 line 1 column 26 near "NO_WRITE_TO_BINLOG table t"
exit status 1
4. What is your TiDB version? (Required)
github.com/pingcap/tidb v1.1.0-beta.0.20231208120617-d23e1c379a52
github.com/pingcap/tidb/pkg/parser v0.0.0-20231208120617-d23e1c379a52
Metadata
Metadata
Assignees
Labels
severity/moderatesig/sql-infraSIG: SQL InfraSIG: SQL Infratype/bugThe issue is confirmed as a bug.The issue is confirmed as a bug.