问题
I am invoking sqlcmd as follows:
sqlcmd -S SERVERNAME\SQLEXPRESS -i "C:\Documents and Settings\user\Desktop\data\bigDB.sql"
And I get an error while the script is executing:
Sqlcmd: Error: Syntax error at line 86626 near command '%' in file 'C:\Documents
and Settings\user\Desktop\data\bigDB.sql'.
How do I tell sqlcmd to ignore the current record and keep running? I think i could edit bigDB.sql and include an :On Error Ignore directive at the top - but the bigDB.sql file is 5GB is size - i cant edit.
Or How could I go to the specific line and delete out the bad record? Thanks for helping.
来源:https://stackoverflow.com/questions/11620594/sqlcmd-runs-into-error-while-parsing-my-sql-file