Re: trigger question
Posted in 1997
Please check the post by Roger Tomas <tomasr@agcs.com> on 97.01.21 about this same problem. It can't be done. Everybody else wants it. From Roger's post: :Call Informix and tell them to add your name to the list of people :who would like this capabilty. Mention feature request # 2566. To Informix Norway who got this by mail: Please add my name as well. Phuoc Ho <ax205@freenet.carleton.ca> wrote: :In an effort to monitor dates entered into the database I wrote a :trigger and procedure to check and correct bad dates. I am :encountering error -747 (Table or column matches object referenced :in triggering statement). It did not make sense to me that you can :not modify the same field that the user is trying to insert or update :in a trigger. Can anyone please let me know if there is a way around :this problem. : :thanks in advance. : :example: : :create trigger npsusers_upd_tr :update on nps_users :referencing old as pre new as post :for each row (execute procedure check_correct(post.date_last_chg) :into date_last_chg); : :*** procedure check_correct modifies the date passed to it Nils.Myklebust@idg.no NM Data AS, P.O.Box 9090 Gronland, N-0133 Oslo, Norway My opinions are those of my company The Informix FAQ is at http://www.iiug.org