Re: STABLE functions

Поиск
Список
Период
Сортировка
От Zeugswetter Andreas SB SD
Тема Re: STABLE functions
Дата
Msg-id 46C15C39FEB2C44BA555E356FBCD6FA4961F8D@m0114.s-mxs.net
обсуждение исходный текст
Ответ на STABLE functions  (Joachim Wieland <jwieland@kawo2.rwth-aachen.de>)
Список pgsql-hackers
> The point at issue is that the "stable function" classification was
> defined and implemented to provide a semantically valid way of deciding
> whether it's safe to treat an expression as an indexscan qualifier.
> There is no code that attempts to do anything else with it.

So the problem at hand seems to be, that the optimizer treats the function
as beeing too cheap (does it apply a cost at all ?). Since this function was in
Pl/SQL it should actually be doable to estimate a cost for the function from
statistics.
Is there a working way to tell the optimizer that the function is expensive,
and thus make it prefer only evaluating it once ?

Andreas



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

Предыдущее
От: Gavin Sherry
Дата:
Сообщение: Re: Prepared queries and ANALYZE
Следующее
От: Gavin Sherry
Дата:
Сообщение: INSERT/UPDATE ... RETURNING