Re: After Trigger assignment to NEW
От | Achilleus Mantzios |
---|---|
Тема | Re: After Trigger assignment to NEW |
Дата | |
Msg-id | Pine.LNX.4.44.0602242138560.20246-100000@matrix.gatewaynet.com обсуждение исходный текст |
Ответ на | Re: After Trigger assignment to NEW (Tom Lane <tgl@sss.pgh.pa.us>) |
Список | pgsql-sql |
O Tom Lane έγραψε στις Feb 24, 2006 : > Achilleus Mantzios <achill@matrix.gatewaynet.com> writes: > > Is there a reason that the NEW values should remain unchanged in AFTER > > row triggers? > > By definition, an AFTER trigger is too late to change what was stored. > Use a BEFORE trigger. Too late if someone wants to store it. I wanna store the intented original values, thats why i use AFTER trigger. But i would like to alter what a final AFTER trigger would see. I'll elabarote a little. An update happens. The row is stored. An after trigger is fired that alters some NEW columns (nullifies them), aiming for a subsequent trigger to see the altered results . It should be something like a pointer to a HeapTuple, (right?), so that would be feasible i suppose. I would not even make a post if it was something that trivial. I hope you get my point. > > regards, tom lane > > ---------------------------(end of broadcast)--------------------------- > TIP 9: In versions below 8.0, the planner will ignore your desire to > choose an index scan if your joining column's datatypes do not > match > -- -Achilleus
В списке pgsql-sql по дате отправления: