MariaDB Error Code -> Windows ERRORLEVEL
Is there a known issue or problem with how/when MariaDB returns error codes from calling '--execute' on *.sql scripts in Windows?
It seems like certain errors are detected and returned as such, and others are not. For example, a *.sql file of completely random bytes will set the Windows ERRORLEVEL=1 after failing, reporting the following error:
ERROR: ASCII '\0' appeared in the statement...
Another *.sql file that references an unknown database will set the Windows ERRORLEVEL=0, but still textually report an error after failing:
ERROR 1049 (42000) at line 1 in file...
Answer Answered by Ian Gilfillan in this comment.
I suggest reporting this as a bug.