Skip to content
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

Allow using unquoted status column identifier in INSERT statements #2195

Closed
knutwannheden opened this issue Sep 28, 2021 · 2 comments
Closed
Assignees

Comments

@knutwannheden
Copy link

Currently when trying to reference a column status in an INSERT statement an error is reported:

create table x(status int);
insert into x(status) values (42);

This is a bit awkward since:

  • in MySQL status is a keyword only and not a reserved word
  • using the status identifier for the column name in the CREATE TABLE statements works fine

I think it would make sense to allow status to be used in unquoted form in the INSERT statement as well. This may also apply to other DML statements.

Additionally, if Dolt SQL is different from MySQL with regards to what are keywords and reserved words, it would make sense to document this.

@VinaiRachakonda VinaiRachakonda self-assigned this Sep 29, 2021
@VinaiRachakonda
Copy link
Contributor

VinaiRachakonda commented Sep 29, 2021

The problem seems to come from our recent work in replication.

For now backticking the column like: insert into x(`status`) values (42); should work

@VinaiRachakonda
Copy link
Contributor

This is now fixed in master

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants