-
Notifications
You must be signed in to change notification settings - Fork 146
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
Dialect support #190
Comments
Yes it does. The same issue is with MariaDB[1] as a fork of MySQL. Besides I see two points here
[1] https://mariadb.com/kb/en/library/comment-syntax/ |
Agree on both of your points. |
Making a quick pass over PR #192 - how about renaming BuiltInDBSpecifics to Dialect? (Yeah, I know some of the things are not quite dialect, but it's near enough, and a lot shorter.) |
Well, I'm ok with such naming. |
I propose a further refactoring:
We arrived at a similar pattern for dialects in Calcite and Mondrian (after many inferior systems over the years), and it worked well. Do those steps sound OK? Maybe I do the refactoring? |
I saw you have already did the great job related to refactoring you mentioned! Thank you. While testing I found several issues but the most critical from my point of view is that any exception while highlight/line continuation check could lead to infinite loop (like it was mentioned in #164 (comment)). It happens because of
The PR where I introduced it is #195 |
There are various behaviors in SQLLine that depend on the particular database. (Keywords, comment syntax, identifier quote string, and others.) This change would gather these into a single class, Dialect.
(The original text of this case dealt with comment syntax in MySQL. We have kept it intact in the following paragraphs. This case is now a more general refactoring, but will also fix the original issue with MySQL comments.)
In MySQL, unlike other databases, "--" is not sufficient to start a comment. It has to be followed by whitespace. Thus:
Does this have an impact on line continuations and/or highlighting?
The text was updated successfully, but these errors were encountered: