|Use the following command to combine |
tmp1.txt and tmp2.txt into FINAL.txt
copy tmp1.txt+tmp2.txt FINAL.txt
for /f "delims=" %%i in ('FINAL.txt^|find /c /v "" ') do set count=%%i
echo total of records is %count%
The total of count is incorrect, because have additional line.
Open the FINAL.txt,noticed that carriage return/line feed is included.
How to remove it? in order to get the total of count is corrected. Thanks!