exclude table from transactions

Поиск
Список
Период
Сортировка
От Kurt
Тема exclude table from transactions
Дата
Msg-id 4B0BFAE6.7040107@gmx.net
обсуждение исходный текст
Ответы Re: exclude table from transactions  (Christophe Pettus <xof@thebuild.com>)
Re: exclude table from transactions  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-general
Dear list,

I'd like to ask, whether there is a way to exclude a table from the
regular transaction rollback.
Background:
I want to log all exceptions caused by my plpgsql-functions in a certain
log-table. To do this, instead of raising an exception directly, i call
a function that writes a record into that log-table and afterwards
raises the exception. But of course, the exception rolls back the INSERT
to the log-table as well. The only solution I came up with till now, is
to put the log data into the exception's error message, parse the
pgsql-logging-file in /var/log with a cron-script and fix the log-table
with that. It works, but it's definitely not a clean solution. So what
I'm looking for, is a table that behaves like a temporary table (e.g.
excluded from WAL and transaction logic), but with the lifetime of a
normal table.
Anybody got an idea?
Thanks in advance, wz



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

Предыдущее
От: erobles
Дата:
Сообщение: which software to replicate a database on windows xp/vista is the best???
Следующее
От: John Oyler
Дата:
Сообщение: Re: I need help creating a composite type with some sort of constraints.