-
Notifications
You must be signed in to change notification settings - Fork 3.8k
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: support placeholder in identifier and literal string positions #8270
Comments
A possible drawback from this approach is that we'd need to double check the typing rules that we can't get conflicting typing between prepare and execute. To alleviate this we could also considering implementing this feature only after we start caching typing information between prepare and execute (another morcel on the roadmap) |
I'm in favor of supporting |
Noooo this is my favorite feature I've wanted since like high school. |
Heh, won't argue with that - I wish there was a way to leave an issue open as "a reasonable idea" without having that also mean "it's on a backlog". |
That is what the C-wishlist label is for! |
e.g.
CREATE TABLE ? (x INT)
orINSERT INTO TABLE X (?, ?) VALUES (1, 2, 3)
So the starting observation is that we have this parser.QueryArguments map which is either empty during prepare (placeholders need to be typed, don't have a value yet) or full during execute. During lexing we can peek into this structure to determine what to do:
cc @mjibson
The text was updated successfully, but these errors were encountered: