-
Notifications
You must be signed in to change notification settings - Fork 3
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
A warning about partial indexes and uniqueness #10
Labels
Comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
To make names unique for partial indexes,
hpqtypes-extras
hashes theWHERE
clause and appends it to the name. PostgreSQL has a hard upper limit for identifiers set to 63 characters, cf. the manual. Now, sincetake 63
is done after processing the whole name, we could end up dropping the hash altogether; suppose the hash isdeadbeef
and witness:It would thus be impossible to have
hpqtypes-extras
define two indexes differing only in the condition for partiality (i.e. differing only in theWHERE
clause).The text was updated successfully, but these errors were encountered: