Re: Referencing NEW values in Trigger
I'm afraid you can't solve all that dynamically. If course, if you'd do it, it would probably perform not too good.
Do your tables definitions change that often? You could just generate the static trigger code from the information schema. In that case, you just have to make sure to generate the trigger anew once you create or alter the table, but that can usually be managed.
Bear in mind that you would already have to generate specific triggers even if you would use your dynamic solution (hence my tablename question), so why not do that properly, and put all the code there you need right away?
It's just a self plug, but it does show some things involved in generating triggers for such a purpose:
http://mysql.gilfster.com/page.php?parent_id=6&page_id=6.0.2
Edited 1 time(s). Last edit at 10/28/2005 04:35PM by Roland Bouman.
Subject
Views
Written By
Posted
5942
October 27, 2005 02:17PM
3311
October 28, 2005 06:58AM
2692
October 28, 2005 03:41PM
Re: Referencing NEW values in Trigger
2822
October 28, 2005 04:33PM
Sorry, you can't reply to this topic. It has been closed.
This forum is currently read only. You can not log in or make any changes. This is a temporary situation.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion
of Oracle or any other party.