-
Notifications
You must be signed in to change notification settings - Fork 152
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
Update snowdialect.py #357
base: main
Are you sure you want to change the base?
Conversation
CLA Assistant Lite bot: I have read the CLA Document and I hereby sign the CLA 1 out of 2 committers have signed the CLA. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
appreciate the contribution! the logic looks good to me, however, I think we could improve code reuse a bit more.
if table_name is not None: | ||
return self._get_table_columns(connection, table_name, schema, **kw) | ||
else: | ||
schema_columns = self._get_schema_columns(connection, schema, **kw) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
could be simplified after code reuse
Optimizations for table-specific metadata lookups
Applied lint black formatting changes
Address unit test failures
Additional unit test fixes.
Unit test fixes
Address unit test failures
Address unit test failures
Address unit test failures
Address unit test failures
linting
Address unit test failures
Refactored identification of reserved word table names
...linted
lint test failure cleanup attempt
an alternative approach to referencing RESERVED_WORDS
Start addressing native sqlalchemy unit test failures
Refactored...
lint'd
Implement optimization changes suggested by sfc-gh-aling. Thank you!
544c4f5
to
bb7965a
Compare
Codecov Report
@@ Coverage Diff @@
## main #357 +/- ##
==========================================
- Coverage 80.03% 79.86% -0.17%
==========================================
Files 8 8
Lines 1177 1182 +5
Branches 186 186
==========================================
+ Hits 942 944 +2
- Misses 174 178 +4
+ Partials 61 60 -1
📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
Optimizations for table-specific metadata lookups
Please answer these questions before submitting your pull requests. Thanks!
What GitHub issue is this PR addressing? Make sure that there is an accompanying issue to your PR.
ref: SNOW-689531
Fill out the following pre-review checklist:
Please describe how your code solves the related issue.
Refine table-specific metadata lookups to target specific tables instead of searching the entire schema for:
- get_columns()
- get_foreign_keys()
- get_pk_contraints()
- get_unique_constraints()
Please write a short description of how your code change solves the related issue.
Allow SHOW metadata lookups for table-level operations to be table-specific.