Trigger for mysql table revision


If I have two tables called person and tax with their columns (id "of type int", name "of type varchar", tax "of type int") and (id "of type int", percentage "of type varchar ", available" of type boolean ") respectively, being the column person.impuesto is a foreign key. How can I create a trigger for the person table that runs in the INSERT and verify that if is equal to true then the INSERT statement is executed correctly, but if equal to false, the INSERT ruling is canceled

asked by Daniel Morales 29.12.2018 в 14:55

0 answers