-
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: currval('') produces bad error message #34527
Comments
well spotted! thanks |
Fixes cockroachdb#34527 This commit checks table name identifier when they use `TablePattern`. Release note (sql change): builtin function `currval` returned the appropriate error associated with the table name.
This error has some trickyness to it too. This function calls our Ok so first attempt at a fix is to use our double quote-style identifier thing. This however breaks the separator |
I take it back: a user would have to correctly quote things in that case. |
We have marked this issue as stale because it has been inactive for |
This bug still exists in v21.1 |
We should do what Postgres does and make currval take in an oid instead of a string. We should then use the same logic as |
The problem here is insufficient checking of preconditions before string interpolation to create the alter table.
In fact, it seems that many of the commands like this one and the privilege checking builtins suffer from lack of string sanitization.
Epic CRDB-8948
The text was updated successfully, but these errors were encountered: