Re: plan invalidation vs stored procedures

Поиск
Список
Период
Сортировка
От Merlin Moncure
Тема Re: plan invalidation vs stored procedures
Дата
Msg-id b42b73150808061133q33083596wd96dbfc948baddf6@mail.gmail.com
обсуждение исходный текст
Ответ на Re: plan invalidation vs stored procedures  ("Marko Kreen" <markokr@gmail.com>)
Ответы Re: plan invalidation vs stored procedures  ("Marko Kreen" <markokr@gmail.com>)
Re: plan invalidation vs stored procedures  (Florian Pflug <fgp.phlo.org@gmail.com>)
Список pgsql-hackers
On Wed, Aug 6, 2008 at 2:28 PM, Marko Kreen <markokr@gmail.com> wrote:
> On 8/6/08, Merlin Moncure <mmoncure@gmail.com> wrote:
>> On Wed, Aug 6, 2008 at 2:20 AM, Marko Kreen <markokr@gmail.com> wrote:
>>  > But the main problem is that if the DROP/CREATE happens, the failure
>>  > mode is very nasty - you get permanent error on existing backends.
>>  > (Main case I'm talking about is functions calling other functions.)
>>  >
>>  > Some sorta recovery mode would be nice to have, it does not even
>>  > need function perfectly.  Giving error once and then recover would
>>  > be better than requiring manual action from admin.
>>
>> sure -- this a known issue --,  but the point is that there are not
>>  that many reasons why you have to drop/create a function if you are
>>  careful.  hiding function prototypes is actually pretty powerful
>>  although you have to deal with creating the extra types.
>
> Um.  If you are talking about about returning type defined by CREATE TYPE
> then you are wrong as changing type requires DROP+CREATE for both type
> and function.

you missed the point...if your return type is a composite type that is
backed by the table (CREATE TABLE, not CREATE TYPE), then you can
'alter' the type by altering the table.  This can be done without full
drop recreate of the function.

merlin


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

Предыдущее
От: "Marko Kreen"
Дата:
Сообщение: Re: plan invalidation vs stored procedures
Следующее
От: "Asko Oja"
Дата:
Сообщение: Re: plan invalidation vs stored procedures