title: Mysql trigger after update insert into another table with condition
body: <p>Below code for my trigger after <strong>update table</strong> <code>student_approve</code> insert data to table notification but <strong>occurs error at line no 5</strong> </p>
  
  <pre><code>DROP TRIGGER IF EXISTS  `student_approve`;
  CREATE TRIGGER `student_approve` AFTER UPDATE ON `student_info` 
  FOR EACH ROW 
  BEGIN
  IF NEW.student_approval LIKE '1' THEN
  INSERT INTO `notifications` (user_to_notify,who_fired_event,noti_event_id)VALUES(NEW.registered_by,1,2);
  END IF;
  END
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/B3A8L.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/B3A8L.png" alt="enter image description here"></a></p>