Repair .sql syntax error