The Microsoft article about using command redirection operators explains the differences on using > or >> or |.
What is wrong with following line?
start "" php index.php 1 2 >>tmp1.txt
This line results in appending output of command start to file tmp1.txt which is not wanted here.
What is the solution?
The redirection operators are no longer interpreted by command processor for command start by escaping the angle brackets with ^, but for php.exe started in a new command process.
start "" php.exe index.php 1 2 ^>^>tmp1.txt
start "" php.exe index.php 3 4 ^>^>tmp2.txt
The disadvantage of the two lines above is that each console window opened for each new process remains open after php.exe finished processing script file index.php.
The solution is using the code provided already by Aacini with starting a new command process with option /C to close the command process and its console window automatically after php.exe terminated.
start "" cmd.exe /C php.exe index.php 1 2 ^>^>tmp1.txt
start "" cmd.exe /C php.exe index.php 3 4 ^>^>tmp2.txt
The redirection can be also specified left of application which output is redirected and appended to the specified file.
start "" cmd.exe /C ^>^>tmp1.txt php.exe index.php 1 2
start "" cmd.exe /C ^>^>tmp2.txt php.exe index.php 3 4
>>tmp1.txtand>>tmp2.txtat the beginning of their respective lines instead.start "" cmd /C ^>^> tmp1.txt php index.php 1 2