-
Notifications
You must be signed in to change notification settings - Fork 1k
feat(ydb): implemented ydb dialect #6624
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
Conversation
|
Thanks for the PR, but there are no plans to accept new dialects at the moment. |
Hi @georgesittas! Any details about this limitation? YDB team would like to support this community dialect. |
|
Maintaining dialects imposes a significant burden on the core SQLGlot team: even if features are contributed by community members, we still have to review everything which is time-consuming & cannot be prioritized at the moment. It should be simple to define this dialect in your application. |
We are focused on integrations with some instruments, that rely on sqlglot. Do you have some examples how to integrate with sqlglot in a plugin-like way? |
Seems like we still have to "extend" sqlglot on every target app. What do you think about not limiting dialect list with DIALECTS dict? We are happy to create a plugin package with |
|
You could create a package that extends it once and then import it in other apps that need to leverage the dialect, no? |
|
Btw, dialects get auto-registered once defined. So you just need to make sure the package where they defined is imported as early as possible so that other sqlglot imports "see" the dialect. |
Yes, but monkey-patching dialect list with As I see https://github.com/tobymao/sqlglot/blob/main/sqlglot/dialects/__init__.py#L119 we are not able to import dialect that is not defined in DIALECTS dict. yes, we can extend it in plugin init file, but
just don't feel right |
|
Makes sense. I think what you described in the relevant issue would make the "plugin flow" better. |
Implementation of YDB dialect for SQLGlot. This PR focuses on adding the YDB SQL dialect generator to support YDB-specific SQL syntax and features.
YDB documentation: https://ydb.tech/