Re: with and trigger

Поиск
Список
Период
Сортировка
От PegoraroF10
Тема Re: with and trigger
Дата
Msg-id 1559135423282-0.post@n3.nabble.com
обсуждение исходный текст
Ответ на Re: with and trigger  (Geoff Winkless <pgsqladmin@geoff.dj>)
Список pgsql-general
Well, I think is not a transaction problem, because if you do the same thing
on a DO it will work. 
DO $$
  declare vMaster_ID integer;
begin
  insert into Master(Customer_ID, Field2) values(1, 'BlaBla') returning
Master_ID into vMaster_ID;
  insert into Detail(Master_ID, Product_ID, ProductValue) values(vMaster_ID,
5, 50);
end $$

As you can see, works exactly the same way and Detail trigger works as
expected, why ?



--
Sent from: http://www.postgresql-archive.org/PostgreSQL-general-f1843780.html



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

Предыдущее
От: Fabrízio de Royes Mello
Дата:
Сообщение: Re: with and trigger
Следующее
От: Tom Lane
Дата:
Сообщение: Re: with and trigger