Re: Cached Query Plans (was: global prepared statements)

Поиск
Список
Период
Сортировка
От Csaba Nagy
Тема Re: Cached Query Plans (was: global prepared statements)
Дата
Msg-id 1208182638.8259.282.camel@PCD12478
обсуждение исходный текст
Ответ на Re: Cached Query Plans (was: global prepared statements)  (Csaba Nagy <nagy@ecircle-ag.com>)
Ответы Re: Cached Query Plans (was: global prepared statements)  (PFC <lists@peufeu.com>)
Список pgsql-hackers
On Mon, 2008-04-14 at 16:10 +0200, Csaba Nagy wrote:
> ... or plan the query with the actual parameter value you get, and also
> record the range of the parameter values you expect the plan to be valid
> for. If at execution time the parameter happens to be out of that range,
> replan, and possibly add new sublpan covering the extra range. This
> could still work with prepared queries (where you don't get any
> parameter values to start with) by estimating the most probable
> parameter range (whatever that could mean), and planning for that.

More on that: recording the presumptions under which the (cached!)plan
is thought to be valid would also facilitate setting up dependencies
against statistics, to be checked when you analyze tables... and if the
key value which you depend on with your query changed, the analyze
process could possibly replan it in the background.

Cheers,
Csaba.




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

Предыдущее
От: Csaba Nagy
Дата:
Сообщение: Re: Cached Query Plans (was: global prepared statements)
Следующее
От: Csaba Nagy
Дата:
Сообщение: Re: Cached Query Plans (was: global prepared statements)