-
Notifications
You must be signed in to change notification settings - Fork 256
Open
Description
func main() {
sql := "SELECT * FROM table WHERE a = 'abc'"
stmt, err := sqlparser.Parse(sql)
if err != nil {
fmt.Printf("%s",err.Error())
}
// Otherwise do something with stmt
switch stmt := stmt.(type) {
case *sqlparser.Select:
_ = stmt
case *sqlparser.Insert:
}
fmt.Printf("stmt :%v", stmt)
}
result err: syntax error at position 20 near 'table'
Metadata
Metadata
Assignees
Labels
No labels