Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Why this returns ELSE is not recognized command
Message
 
 
To
23/02/2021 15:42:34
General information
Forum:
Windows
Category:
DOS commands
Miscellaneous
Thread ID:
01678538
Message ID:
01678554
Views:
42
Hi Naoto,

My latest code is
IF (NOT EXIST %Main_PATH%File_Extract\Status\File_Extract_Main%JobNbr%_OK.txt) (
	REM powershell -NoProfile -ExecutionPolicy Bypass -Command "Write-EventLog -LogName 'VACCN' -Source 'DataRepo' -EventID 5120 -EntryType Error -Message 'Fatal error in VA Extract process.'"
	REM call %Main_PATH%EventWriterWriter\Scripts\release\EventWriter.exe %JobNbr% "DR_101" "batchfile" "Fatal error in VA Extract process."
	EXIT 11
) ELSE (
	REM powershell -NoProfile -ExecutionPolicy Bypass -Command "Write-EventLog -LogName 'VACCN' -Source 'DataRepo' -EventID 5100 -EntryType Information -Message 'Successful completion of Extract Job 89.'"
	REM echo “Successful completion”
	EXIT
)
and it returned from the job:
EXIST was unexpected at this time. Process Exit Code 255. The step failed.

Do you see what may be wrong and why the status is 255?

UPDATE. Found this https://stackoverflow.com/questions/11619564/weird-ssis-error-process-exit-code-255 which doesn't explain exactly what was going on, but somewhat.

Thanks.
If it's not broken, fix it until it is.


My Blog
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform