MySQL Forums
Forum List  »  Triggers

Triggers question!
Posted by: Max Molina
Date: August 25, 2016 03:09PM

Internet! I require some assistance in creating triggers. I am a bit new to mysql, but I've done everything by myself so far and I need a bit of help with triggers.


Now, I have a master_table, and some colmuns get a 'yes' or 'no' enum data type value on certain columns. I need a trigger so that when I INSERT/UPDATE/DELETE a row in the master table, it is added/deleted from the child tables.

Say one row gets a 'yes' in column G. I need that record to be added with the information from colmuns a,b,c,d,e,f into the child table.

I've seen some examples but none do what I need and i require some help in the coding part. I am using phpMyadmin. I do have a foreign key inserted into my child talbes. master_table uses id_xxxx and the same column is into the child tables. the columns in the child tables have the same data types and columns. I just need example code for the triggers.

Options: ReplyQuote


Subject
Views
Written By
Posted
Triggers question!
1026
August 25, 2016 03:09PM
433
August 25, 2016 06:35PM
496
August 25, 2016 10:06PM
390
August 26, 2016 08:48AM
486
August 26, 2016 02:51PM
467
August 26, 2016 07:26PM


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.