If you are trying to run arbitrary code from a Windows .BAT file, the following almost works:
ECHO ZN "%%SYS" DO ^^^^SECURITY HALT | C:\InterSystems\Cache\bin\cache.exe -s C:\InterSystems\Cache\mgr
The limitations are:
- You have to specify the locations of the Caché or IRIS executable and the \mgr directory with an -s option.
- One cannot redirect command input from the terminal, so what you run can't be interactive.
- Quoting for Windows may annoy you.