Files
FT546MWS/scripts/layer1-inbound-pilot/rollback-layer1-inbound-pilot.cmd

17 lines
405 B
Batchfile

@echo off
setlocal
if "%~1"=="" goto :usage
if "%~2"=="" goto :usage
if /I not "%~3"=="CONFIRM_LAYER1_PILOT_ROLLBACK" (
goto :usage
)
set "SCRIPT_DIR=%~dp0"
sqlcmd -S "%~1" -d "%~2" -E -b -r1 -i "%SCRIPT_DIR%rollback-layer1-inbound-pilot.sql"
if errorlevel 1 exit /b 1
echo LAYER1_INBOUND_PILOT_ROLLBACK_OK
exit /b 0
:usage
echo Usage: %~nx0 SQL_SERVER DATABASE CONFIRM_LAYER1_PILOT_ROLLBACK
exit /b 2