Skip to content
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

General strategy for specifying <database>.<schema>.<table_name> in LazyTbl #400

Open
machow opened this issue Mar 3, 2022 · 0 comments

Comments

@machow
Copy link
Owner

machow commented Mar 3, 2022

SQL databases differ in the number of levels in a database. E.g.

  • postgres: you connect to a database, can specify a .<table_name>
  • snowflake: you can specify all three - ..<table_name>
  • bigquery: to my knowledge is similar to snowflake, but the sqlalchemy implementation has funny behavior around the schema piece (which bigquery calls datasets. But to be sure, also calls schemas in rare parts of the docs).

Currently, LazyTbl just does a simple str.split("."), that expects 2 components. Let's figure out a general way to let users specify as many levels as the database and underlying sqlalchemy dialect allow.

Note, as an alternative, siuba could bake this in somehow to the dialects. (but I would rather lean on the dialect implementation if possible).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: No status
Development

No branches or pull requests

1 participant