Fix syntax error inside sql triggers