Articles Comments

{ Berbagi, Menulis, Dan Mengajar } Ilmu… » 7. Operating System » Trigger DELETE DATA

Trigger DELETE DATA

DELIMITER $$

USE `sms2`$$

DROP TRIGGER /*!50032 IF EXISTS */ `DeletePbk`$$

CREATE
/*!50017 DEFINER = ‘dimas’@’%’ */
TRIGGER `DeletePbk` AFTER DELETE ON `pbk`
FOR EACH ROW BEGIN

DELETE FROM pbk_copy WHERE pbk_copy.id_pbk=OLD.id_pbk;

END;
$$

DELIMITER ;

Filed under: 7. Operating System

Leave a Reply

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>