Re: BUG #13348: PostgreSQL 9.5 sampletable BUG return rows not the same as reltuples*sample factor? - Mailing list pgsql-bugs

From Tom Lane
Subject Re: BUG #13348: PostgreSQL 9.5 sampletable BUG return rows not the same as reltuples*sample factor?
Date
Msg-id 10017.1432570191@sss.pgh.pa.us
Whole thread Raw
In response to BUG #13348: PostgreSQL 9.5 sampletable BUG return rows not the same as reltuples*sample factor?  (digoal@126.com)
List pgsql-bugs
digoal@126.com writes:
> But when use BERNOULLI sample method, it's return rows not the same as
> reltuples*factor.
> Can we add filter to exact return rows equal to reltuples*factor ?

No.  It is neither practical nor required by the standard that the number
of returned rows be exactly N*S.  If we tried to do that, rows near the
end of the table would end up having a different probability of being
selected than rows near the front.

            regards, tom lane

pgsql-bugs by date:

Previous
From: digoal@126.com
Date:
Subject: BUG #13348: PostgreSQL 9.5 sampletable BUG return rows not the same as reltuples*sample factor?
Next
From: Alvaro Herrera
Date:
Subject: Re: Incorrect processing of CREATE TRANSFORM with DDL deparding