-
Notifications
You must be signed in to change notification settings - Fork 32
feat: support schemas in queries and dml statements #639
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
Merged
Conversation
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
35bfd71
to
5f851b8
Compare
Open
5f851b8
to
830109d
Compare
Add support for SELECT, UPDATE and DELETE statements against tables in schemas. Schema names are not allowed in Spanner SELECT statements. We need to avoid generating SQL like ```sql SELECT schema.tbl.id FROM schema.tbl ``` To do so, we alias the table in order to produce SQL like: ```sql SELECT tbl_1.id, tbl_1.col FROM schema.tbl AS tbl_1 ```
830109d
to
d947102
Compare
d7c7506
to
9ddee8b
Compare
In sqlalchemy 2.0, it's: ```python self._label_select_column(None, c, True, False, {}, include_table=False) ``` In older versions, it's ```python self._label_select_column(None, c, True, False, {'include_table': False}) ``` So instead, forward a flag to `vist_column` which can set this kwarg safely itself.
9ddee8b
to
2638b77
Compare
olavloite
approved these changes
May 2, 2025
@waltaskew Thank you for this great contribution! |
Thanks for reviewing and accepting! Do you have any plans around when the next release of the library will be? |
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.
Add support for SELECT, UPDATE and DELETE statements against tables in
schemas.
Schema names are not allowed in Spanner SELECT statements. We need to
avoid generating SQL like
To do so, we alias the table in order to produce SQL like: