-
Notifications
You must be signed in to change notification settings - Fork 605
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
feat: list materialized views #5962
Comments
Relatedly, I wonder whether |
Hi @dpprdan 👋🏻! Thanks for creating an issue about this. Listing materialized views in As far as DDL for Here are the backend we support in ibis that support materialized views along with links to their documentation:
|
Those inspector methods appear to be SQLAlchemy 2.0 only, and ibis supports SQLAlchemy<2 so we'd need to figure out a way to get that information without relying on 2.0-only APIs. |
AFAICT it is the other way around? I see "New in version 1.0.0." for Should we split the matview-DDL issue from this "list matviews" issue? |
Ah, yep, you're right!
Yeah, definitely. |
Closing in favor of #8382. Thanks for the discussion! |
Is your feature request related to a problem?
ibis does not
list_tables()
materialized views in Postgres.Describe the solution you'd like
IIUC (and that’s a big IF as I’ve been trying out Ibis only for a few days now) is using these SQLAlchemy inspector functions.
ibis/ibis/backends/base/sql/alchemy/__init__.py
Lines 101 to 104 in 6b2cbaa
Fortunately, SQLAlchemy has gained a
get_materialized_view_names()
function in version 2.0.So a fix might possibly be as easy as (plus a SQLAlchemy version check)
get_materialized_view_names()
seems to behave if an engine does not support materialized views (yet).Ideally Ibis would support materialized views even more, of course, e.g. with
create_materialized_view()
,refresh_materialized_view()
, anddrop_materialized_view()
.Accessing materialized views does not seem to be a problem.
What version of ibis are you running?
5.0.0
What backend(s) are you using, if any?
PostgreSQL (DuckDB as a does-not-support-matviews backend)
Code of Conduct
The text was updated successfully, but these errors were encountered: