-
Notifications
You must be signed in to change notification settings - Fork 94
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
Add new functions index_is_partial #342
base: main
Are you sure you want to change the base?
Conversation
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.
I’m not at the job where I needed this, but this looks like it would do exactly what I wanted for partial index detection. It doesn't (yet?) implement the index_partial_clause_is
test, but that was always secondary from my perspective.
Happy to read this @halostatue |
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.
Looks good, aside from the wrong function names in the upgrade script. Please also rebase on main. Thanks!
$$ LANGUAGE sql; | ||
|
||
-- index_is_partial( table, index ) | ||
CREATE OR REPLACE FUNCTION index_is_partial ( NAME, NAME ) |
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.
All of these can be pure SQL I think.
Co-authored-by: David E. Wheeler <46604+theory@users.noreply.github.com>
Add new function to check partial indexes as requested in #334