Does mysql support some kind of table listeners? It would be nice if I could tell mysql to trigger external script with some options when table is changed.
For example i have some script or daemon running on background and when mysql table is changed
script is called script -opt1 opt2 etc
Is it possible? Is there anything like that already?
The problem is, that i need to renew cache on my app when mysql tables are changed.
Thanks 😉
You can call up any piece of code from inside a trigger, as suggested by Bobby; this can be a stored procedure or an external function. See here for how to create external functions (it looks a bit fraught to me though).