Re: temp tables and sequences in functions

Поиск
Список
Период
Сортировка
От A. Kretschmer
Тема Re: temp tables and sequences in functions
Дата
Msg-id 20070905140544.GB19358@a-kretschmer.de
обсуждение исходный текст
Ответ на temp tables and sequences in functions  (Rob <motorhead9876@yahoo.com>)
Список pgsql-general
am  Wed, dem 05.09.2007, um  6:58:30 -0700 mailte Rob folgendes:
> What is the proper why to deal with temp tables and sequences? Why aren't they
> being dropped after the function ends? Why do I get OID errors if I delete the
> temp table/sequence at the end of the function and then try to rerun the
> function?
>
> ERROR: could not open relation with OID 58341
> SQL state: XX000

normal behavior. Read more about this problem here:
http://merlinmoncure.blogspot.com/2007/09/as-previously-stated-postgresql-8.html

Solution: use EXECUTE for DDL-commands inside functions.


Andreas
--
Andreas Kretschmer
Kontakt:  Heynitz: 035242/47150,   D1: 0160/7141639 (mehr: -> Header)
GnuPG-ID:   0x3FFF606C, privat 0x7F4584DA   http://wwwkeys.de.pgp.net

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

Предыдущее
От: Rob
Дата:
Сообщение: temp tables and sequences in functions
Следующее
От: SHARMILA JOTHIRAJAH
Дата:
Сообщение: how to find the number of rows inserted into the master table?