transaction and triggers

Поиск
Список
Период
Сортировка
От Gerardo Herzig
Тема transaction and triggers
Дата
Msg-id 4790B50A.5050101@fmed.uba.ar
обсуждение исходный текст
Ответы Re: transaction and triggers  ("Filip Rembiałkowski" <plk.zuber@gmail.com>)
Список pgsql-sql
Hi all. Im puzzled again. Just thinking:

As im having fun trying to make my own replication system, im stuck in 
this situation:
Consider a simple table with a unique index on the `id' field, and a 
function who will fail, such as

insert into test (id) values (1);
insert into test (id) values (1);

This will fail and the transaction will be rollback'ed, but as the basis 
of my replication system is on row level triggers, the first time the 
insert is called, the trigger will be executed, and i will like to be 
able to stack the triggers in some way, in order to be fired only after 
a succesfull execution of the hole function.

Im also reading the NOTIFY/LISTEN mechanism and the rule system as a 
workarround on this, but the fact is that there is a lot of client code, 
and will take a big amount of time to change it.

Any sugestions?

Thanks!
Gerardo


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

Предыдущее
От: Kevin Jenkins
Дата:
Сообщение: Re: How to test/read a stored procedure that returns a boolean?
Следующее
От: "Filip Rembiałkowski"
Дата:
Сообщение: Re: transaction and triggers