Re: BUG #17594: conditional hash indexes size (hash index ignore WHERE condition during CREATE INDEX?) - Mailing list pgsql-bugs

From Tom Lane
Subject Re: BUG #17594: conditional hash indexes size (hash index ignore WHERE condition during CREATE INDEX?)
Date
Msg-id 1573189.1661460549@sss.pgh.pa.us
Whole thread Raw
In response to BUG #17594: conditional hash indexes size (hash index ignore WHERE condition during CREATE INDEX?)  (PG Bug reporting form <noreply@postgresql.org>)
Responses Re: BUG #17594: conditional hash indexes size (hash index ignore WHERE condition during CREATE INDEX?)
List pgsql-bugs
PG Bug reporting form <noreply@postgresql.org> writes:
> I found very weird situation with size of highly selective partial hash
> indexes (they has almost same size as full table hash index).

hashbuild() sets up the initial hash index size based on estimating
the current number of rows in the table, without any correction for
partial-index selectivity.  I don't find this to be a bug particularly.
The odds of making things worse via a bad estimate seem at least as
high as the odds of making things better.

            regards, tom lane



pgsql-bugs by date:

Previous
From: PG Bug reporting form
Date:
Subject: BUG #17594: conditional hash indexes size (hash index ignore WHERE condition during CREATE INDEX?)
Next
From: Scott Zelenka
Date:
Subject: Re: BUG #17593: min key size 112 bits from FIPS SP800-131 requirement for HMAC-SHA raises exception in SCRAM-SHA-256