mysql triggers and  references