Re: Call for objections: simplify stable functions during estimation

Поиск
Список
Период
Сортировка
От Robert Treat
Тема Re: Call for objections: simplify stable functions during estimation
Дата
Msg-id 200411091343.57610.xzilla@users.sourceforge.net
обсуждение исходный текст
Ответ на Call for objections: simplify stable functions during estimation  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: Call for objections: simplify stable functions during estimation  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
On Tuesday 09 November 2004 11:28, Tom Lane wrote:
> Awhile back, there was some discussion about pre-folding now() and
> related functions when the planner is trying to estimate selectivities.
> This would allow reasonable plans to be made for cases like
>  WHERE moddate >= current_date - 10;
> without having to indulge in any crude hacks with mislabeled wrapper
> functions, such as you can find all too often in the archives :-(
>
> I was a bit hesitant about it at the time because I wasn't sure of all
> the implications; but I've looked the idea over again, and as far as I
> can see it's reasonable to pre-fold *all* stable functions when deriving
> statistical estimates.  (One of the potential objections went away when
> we started enforcing that stable functions don't have side-effects.)
>

Since we know people will be calling volatile functions inside stable 
functions (see thread from last week if you need a refresher as to why) is 
there any serious negative side-effect in those cases?

-- 
Robert Treat
Build A Brighter Lamp :: Linux Apache {middleware} PostgreSQL


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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: [GENERAL] server auto-restarts and ipcs
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Call for objections: simplify stable functions during estimation