change trigger.sql to fit mysql5.1