Page 1 of 1

PHP in Mysql Integration

Posted: Sun May 11, 2003 9:07 pm
by magna
Hey, i have heard that i could get PHP in a MySql database that will execute everytime you retrieve the table infomation, is this true?

Posted: Mon May 12, 2003 2:54 am
by twigletmac
You can use eval() to execute PHP code stored within a database but I'd avoid that if at all possible and have the PHP code within normal files.

Mac

Posted: Mon May 12, 2003 5:57 am
by volka
sounds like you're asking for triggers
http://www.mysql.com/doc/en/ANSI_diff_Triggers.html
Triggers will also be implemented. A trigger is effectively a type of stored procedure, one that is invoked when a particular event occurs. For example, you can install a stored procedure that is triggered each time a record is deleted from a transaction table and that stored procedure automatically deletes the corresponding customer from a customer table when all his transactions are deleted.
strange, the german translation states that stored procedures will be implemented but without triggers :?