Re: plan invalidation vs stored procedures
От | Tom Lane |
---|---|
Тема | Re: plan invalidation vs stored procedures |
Дата | |
Msg-id | 4793.1217944277@sss.pgh.pa.us обсуждение исходный текст |
Ответ на | Re: plan invalidation vs stored procedures (Martin Pihlak <martin.pihlak@gmail.com>) |
Ответы |
Re: plan invalidation vs stored procedures
Re: plan invalidation vs stored procedures |
Список | pgsql-hackers |
Martin Pihlak <martin.pihlak@gmail.com> writes: > create function foo() returns integer as $$ begin return 1; end; $$ language plpgsql; > CREATE FUNCTION > prepare c1 as select * from foo(); > PREPARE > execute c1; > foo > ----- > 1 > (1 row) > drop function foo(); > DROP FUNCTION > create function foo() returns integer as $$ begin return 2; end; $$ language plpgsql; > CREATE FUNCTION > execute c1; > psql:test.sql:11: ERROR: cache lookup failed for function 36555 This is simply a bad, wrong, stupid way to do it. Why do you not use CREATE OR REPLACE FUNCTION? regards, tom lane
В списке pgsql-hackers по дате отправления: