Re: Trigger referencing another table and calling SP
It seems that CALL is now (5.0.10) supported from within a trigger:
mysql> use test;
Database changed
mysql> create table t(id int );
Query OK, 0 rows affected (0.16 sec)
mysql> delimiter $$
mysql> create procedure p()begin declare i int; set i:= 1; end;
-> $$
Query OK, 0 rows affected (0.00 sec)
mysql> create trigger test_trigger1 before insert on test.t for each row begin call p(); end;
-> $$
Query OK, 0 rows affected (0.00 sec)
By the looks of it, you can even reference another table from within that procedure.
Anyone to verify?
Subject
Views
Written By
Posted
4199
June 11, 2005 09:54AM
2922
June 12, 2005 08:41AM
2481
June 20, 2005 08:04PM
2513
June 21, 2005 01:43AM
2528
June 26, 2005 10:44PM
9686
June 27, 2005 01:01AM
2831
June 27, 2005 11:32PM
Re: Trigger referencing another table and calling SP
4246
July 28, 2005 09:35AM
Sorry, you can't reply to this topic. It has been closed.
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.