Added support for 'ALTER TABLE CHANGE COLUMN'#741
Merged
wumpz merged 4 commits intoJSQLParser:masterfrom Feb 7, 2019
Merged
Conversation
Now also test the getOptionalSpecifier() for both cases (null and not-null)
Member
|
Could you write tests using assertSqlCanBeParsedAndDeparsed as well. The deparser should be able to completely reconstruct the source SQL. |
Contributor
Author
|
Oh, yes, sorry. I had them as test earlier but apparently managed to remove them along the way. I added the requested tests back in. Edit: I am not really sure where the reduction on coverage comes from. Is it a lack of explicit tests of the new setter methods? |
Member
|
The reduction on coverage or the coverage value itself seems to be some kind of black magic to me as well. Sometimes the increase or decrease has no clear source. |
PraTrick
added a commit
to PraTrick/JSqlParser
that referenced
this pull request
Feb 16, 2019
* changed license header to represent the projects dual license * changed license header to represent the projects dual license * changed license header to represent the projects dual license * changed license header to represent the projects dual license * Added support for comment(s) for column definitions in CREATE TABLE s… (JSQLParser#743) * Added support for comment(s) for column definitions in CREATE TABLE statements * Added support for comment(s) for column definitions in CREATE TABLE statements #2 * To increase code coverage * To increase code coverage #2 * Added support for 'ALTER TABLE CHANGE COLUMN' (JSQLParser#741) * Added support for 'ALTER TABLE CHANGE COLUMN oldName newName columnDefinition'. Please see https://dev.mysql.com/doc/refman/8.0/en/alter-table.html for reference. * Returned import ordering to avoid conflicts * Improved the tests somewhat Now also test the getOptionalSpecifier() for both cases (null and not-null) * Expanded tests for ALTER TABLE ... CHANGE * implemented optimize for, fixes JSQLParser#348 * implemented optimize for, fixes JSQLParser#348 * Support for simple informix outer joins. (JSQLParser#745) * added support for simple informix outer joins added some test code * added support for simple informix outer joins added some test code * more testing for better code coverage * added support for simple informix outer joins added some test code * more testing for better code coverage * fixes JSQLParser#747 * fixes JSQLParser#733 * fixes JSQLParser#707 * Update README.md * Update README.md
wumpz
pushed a commit
that referenced
this pull request
Feb 19, 2019
…752) * Merge recent changes in the master from the master (#1) * changed license header to represent the projects dual license * changed license header to represent the projects dual license * changed license header to represent the projects dual license * changed license header to represent the projects dual license * Added support for comment(s) for column definitions in CREATE TABLE s… (#743) * Added support for comment(s) for column definitions in CREATE TABLE statements * Added support for comment(s) for column definitions in CREATE TABLE statements #2 * To increase code coverage * To increase code coverage #2 * Added support for 'ALTER TABLE CHANGE COLUMN' (#741) * Added support for 'ALTER TABLE CHANGE COLUMN oldName newName columnDefinition'. Please see https://dev.mysql.com/doc/refman/8.0/en/alter-table.html for reference. * Returned import ordering to avoid conflicts * Improved the tests somewhat Now also test the getOptionalSpecifier() for both cases (null and not-null) * Expanded tests for ALTER TABLE ... CHANGE * implemented optimize for, fixes #348 * implemented optimize for, fixes #348 * Support for simple informix outer joins. (#745) * added support for simple informix outer joins added some test code * added support for simple informix outer joins added some test code * more testing for better code coverage * added support for simple informix outer joins added some test code * more testing for better code coverage * fixes #747 * fixes #733 * fixes #707 * Update README.md * Update README.md * Fix handles the following cases: 1) DROP INDEX 2) ADD UNIQUE INDEX 3) ALGORITHM 4) USING <index type>
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.
Added support for 'ALTER TABLE CHANGE COLUMN oldName newName columnDefinition'.
Please see https://dev.mysql.com/doc/refman/8.0/en/alter-table.html for reference.
I was not really sure how to modify the AlterStatement class. I found introducing these two new fields was the easiest solution, but I am open to suggestions should there be a better way of doing it.
Also, this is my first time writing anything in JavaCC, so if I've made some obvious mistakes or bad practises, I would gladly take feedback.
This should fix #380 and parts of #571