Add OFFSET to LIMIT clause, updated active pull requests#8
Merged
andykent merged 3 commits intoforward:masterfrom Mar 17, 2015
Merged
Add OFFSET to LIMIT clause, updated active pull requests#8andykent merged 3 commits intoforward:masterfrom
andykent merged 3 commits intoforward:masterfrom
Conversation
…N, ANY, ALL, SOME, EXISTS. Allow COUNT(DISTINCT columns). Allow <=, >=, <>, !=.
* @numtel Added grammar changes and test case
* MySQL style LIMIT Number, Number also now supported
andykent
added a commit
that referenced
this pull request
Mar 17, 2015
Add OFFSET to LIMIT clause, updated active pull requests
Contributor
|
Thanks for sorting this. Sorry for the neglect to the project. I'll bump the version and re-release now. |
Contributor
|
I forgot to say. With regards to the backtick escaping... I'm not sure what the right move is here. So far Things have been fairly non-specific to particular DBs but I guess at some point things will need to get more directed. I just really don't want to have to maintain different forks of the Grammer for different DBs. Escaping is an easy one to solve but different keywords in queries starts to be come quite awkward to manage. I'll have a go at escaping support now. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Hello @andykent
Thanks so much for this project! I have merged the pull request from @davidcrawford as well as the one from @bjornharrtell (Including the necessary changes to the grammar file and added a test).
Along with the already existing pull requests, I have added support for OFFSET on the LIMIT clause. MySQL style
LIMIT offset, row_countis also now supported. As well as MS SQL style OFFSET/FETCH syntax.Also, although not fixed in this PR, the
toString()method seems to only support MySQL style identifiers being wrapped in backticks. Postgres (and I think MSSQL) use double-quotes. It may be helpful to have some kind of option to toggle this output.If you would be kind enough to release a new version to NPM, that would be much appreciated.
-Ben