views:

17

answers:

1

Hi,

I want to create the Trigger which calls a php script and also passes parameters to php

CREATE TRIGGER trigger_test AFTER Update ON table1 where status_message = "done"
FOR EACH ROW

BEGIN
  \! echo "php /Email.php" >> /tmp/yourlog.txt
END;

how can I get data for the row updated.

Regards, NewDev

A: 

Calling external applications from triggers is possible, but not trivial.

One way to do it is using the sys_exec() function ( found at this User-Defined Function ).

Konerak