-
Notifications
You must be signed in to change notification settings - Fork 48
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
Add additional clauses/keywords to the insert statement #118
Conversation
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.
Please split up the compound keywords like ON CONFLICT
@@ -948,18 +954,44 @@ module.exports = grammar({ | |||
), | |||
|
|||
insert: $ => seq( | |||
choice($.keyword_insert, $.keyword_replace), | |||
$.keyword_into, |
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.
why is keyword_into
now optional? For which dialect is this change?.
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.
MySQL does not require it - I thought it was always optional but apparently not. [1] is the MySQL reference
SQL Server does not require it either it appears [2]
[1] - https://dev.mysql.com/doc/refman/8.0/en/insert.html
[2] - https://learn.microsoft.com/en-us/sql/t-sql/statements/insert-transact-sql?view=sql-server-ver16
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.
Ah yes. Before your PR the grammar required an INTO
keyword, but it looks like it is optional in MySQL and MariaDB as well.
57cb35f
to
de17c23
Compare
de17c23
to
080c9f1
Compare
No description provided.