Re: Wording in TABLESAMPLE documentation

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Simon Riggs <simon(at)2ndquadrant(dot)com>
Cc: "Patrik VV(dot)" <paddor(at)gmail(dot)com>, pgsql-docs(at)postgresql(dot)org
Subject: Re: Wording in TABLESAMPLE documentation
Date: 2016-08-12 17:54:54
Message-ID: 7639.1471024494@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-docs

Simon Riggs <simon(at)2ndquadrant(dot)com> writes:
> On 12 August 2016 at 16:23, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
>> I think "global" might have implications we don't want. How about
>> adding ", based on a system-generated seed"?

> What I was trying to express was that

> SELECT setseed(dp);
> SELECT * FROM foo TABLESAMPLE ...;
> SELECT * FROM foo TABLESAMPLE ...;
> SELECT * FROM foo TABLESAMPLE ...;

> would yield a repeatable set of samples, similarly repeatable but not
> same samples as

> SELECT * FROM foo TABLESAMPLE ... REPEATABLE;
> SELECT * FROM foo TABLESAMPLE ... REPEATABLE;
> SELECT * FROM foo TABLESAMPLE ... REPEATABLE;

But that's *wrong*. Not all tablesample methods make any such guarantee.
In fact, neither of our contrib methods do. Only if you use REPEATABLE
(and the method allows it) is there any promise at all about repeatability.

regards, tom lane

In response to

Responses

Browse pgsql-docs by date

  From Date Subject
Next Message Simon Riggs 2016-08-12 17:59:16 Re: Wording in TABLESAMPLE documentation
Previous Message Simon Riggs 2016-08-12 17:50:57 Re: Wording in TABLESAMPLE documentation