Hi,
Not tried it by myself but may be useful to you:
sqlcmd <yourscript>
IF ERRORLEVEL 1 goto err_handler
goto done
:err_handler
REM handle the error here
:done
REM script completion code here
Ref: http://stackoverflow.com/questions/5795430/error-handling-with-batch-file-sqlcmd