-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
[CT-434] [Feature] PostGres partial index #4970
Comments
@kmedara-wr Sorry for the delay getting back to you! I'm not a Postgres expert, so I was initially a bit skeptical—why not just a new table (filtered projection) that can have a simpler "full" index?—but the docs set me straight:
In terms of the syntax you're proposing: The Implementation detailsAdd a new attribute (whichever it's called — dbt-core/plugins/postgres/dbt/adapters/postgres/impl.py Lines 19 to 23 in 6267572
In the docs, it looks like there's no partial "type," in the sense of passing through the keyword Then, update the dbt-core/plugins/postgres/dbt/include/postgres/macros/adapters.sql Lines 17 to 30 in 6267572
Finally, add a new test case to I think all of those steps are fairly straightforward and self-contained, so I'm going to mark this a |
@jtcohen6 yea! sounds like a fun knowledge gainer. thank you for the details |
@kmedara-wr are you tackling this? I'd love to give it a shot |
@alswang18 Yes this is something I'm working on, if I hit any blockers I'll certainly reach out though |
This issue has been marked as Stale because it has been open for 180 days with no activity. If you would like the issue to remain open, please remove the stale label or comment on the issue, or it will be closed in 7 days. |
Although we are closing this issue as stale, it's not gone forever. Issues can be reopened if there is renewed community interest; add a comment to notify the maintainers. |
I'm quite interested in being able to declare PostgreSQL partial indexes in dbt. @kmedara-wr, did you get a chance to implement a change? |
I'm interested in this change as well @kmedara-wr @alswang18 |
Any new on this? This would be very good to have |
Also interested in this, it's essential for picking out common cases that represent a small fraction of records a large table (that you do not want to turn into its own intermediate table). |
Is there an existing feature request for this?
Describe the Feature
I understand since 0.20.0 you there is native support for indexes. but I could not find anything for partial indexes..something like
or
Describe alternatives you've considered
No response
Who will this benefit?
No response
Are you interested in contributing this feature?
No response
Anything else?
https://docs.getdbt.com/reference/resource-configs/postgres-configs
The text was updated successfully, but these errors were encountered: