-
Notifications
You must be signed in to change notification settings - Fork 66
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
sql (fix): Digit identifier must be quoted #3482
Conversation
bb86c9d
to
b50da89
Compare
b50da89
to
2b3e9d2
Compare
override def sqlExpr: String = value | ||
override def toString: String = s"Id(${value})" | ||
override def sqlExpr: String = s""""${value}"""" | ||
override def toString: String = s"""Id("${value}")""" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No need to quote this string representation
@takezoe I think DigitIdentifiers are intended for representing |
Ah, I see.
Assuming the following query, "123" is parsed as a digit identifier SELECT * FROM database."123" and regenerated SQL from the AST will be invalid: SELECT * FROM database.123 Now I found the root cause is that a digit identifier is generated in airframe/airframe-sql/src/main/scala/wvlet/airframe/sql/model/Expression.scala Lines 459 to 472 in eb3c43e
|
Created #3493 |
No description provided.