Re: Variable LIMIT and OFFSET in SELECTs

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Variable LIMIT and OFFSET in SELECTs
Дата
Msg-id 5823.1195148708@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Variable LIMIT and OFFSET in SELECTs  (Sam Mason <sam@samason.me.uk>)
Ответы Re: Variable LIMIT and OFFSET in SELECTs
Список pgsql-general
Sam Mason <sam@samason.me.uk> writes:
> On Thu, Nov 15, 2007 at 06:08:20PM +0100, Reg Me Please wrote:
>> But then why allowing the LIMIT and the OFFSET as coming from function
>> argument evaluations?

> I believe the query is planned by ignoring the LIMIT and OFFSET.

No, it still knows there will be a LIMIT in effect, but it has to guess
at how tight the limit is.  From memory I think it assumes 10% of the
total rows will be retrieved, which is a compromise to try to avoid
being spectacularly bad for either small or large limits.

            regards, tom lane

В списке pgsql-general по дате отправления:

Предыдущее
От: "Martin Gainty"
Дата:
Сообщение: Re: Compiled debugger plug in for windows, any one have it?
Следующее
От: "Joshua D. Drake"
Дата:
Сообщение: Re: PLpgsql debugger question