Re: Using TEMP ON COMMIT DROP, but need logging too.

Поиск
Список
Период
Сортировка
От Michael Moore
Тема Re: Using TEMP ON COMMIT DROP, but need logging too.
Дата
Msg-id CACpWLjNCu9X10g8GFMoFMJfFTFyQUXqnSGutzonyHHkyBYHG9A@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Using TEMP ON COMMIT DROP, but need logging too.  ("David G. Johnston" <david.g.johnston@gmail.com>)
Ответы Re: Using TEMP ON COMMIT DROP, but need logging too.  (Michael Moore <michaeljmoore@gmail.com>)
Список pgsql-sql
Thanks David. I didn't know that as I have only written retrieval functions as of now. I'm going back to do some due diligence. 

On Thu, Oct 13, 2016 at 2:48 PM, David G. Johnston <david.g.johnston@gmail.com> wrote:
On Thu, Oct 13, 2016 at 2:24 PM, Michael Moore <michaeljmoore@gmail.com> wrote:
I've written a function that uses several temporary tables with the ON COMMIT DROP option. This function does no updates to the database. Now I would like to put in some logging. In otherwords:

insert into my_logging_table values (...);
commit;

Obviously I can't do the commit without dropping my temp tables. 

What is a good way to implement my intended functionality?


​You can't put "commit" inside a function so I feel like you are failing to share some important details by not providing code.

David J.
 

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

Предыдущее
От: "David G. Johnston"
Дата:
Сообщение: Re: Using TEMP ON COMMIT DROP, but need logging too.
Следующее
От: Ranjeet Verma
Дата:
Сообщение: Table Partitioning with Foreign Data Wrapper