sql script error fixed