Im not clear what you want to do but have you looked at triggers?
By placing triggers on a table you can intercept a command and get the system to behave in a customised way.
Personally Im not too keen on lots of triggers as they make maintenance and debugging difficult but sometimes thay are the only way.