Concatenate text files with Windows command line, dropping leading lines

前端 未结 12 831
心在旅途
心在旅途 2020-11-30 18:03

I need to concatenate some relatively large text files, and would prefer to do this via the command line. Unfortunately I only have Windows, and cannot install new software.

12条回答
  •  有刺的猬
    2020-11-30 19:04

    I use this, and it works well for me:

    TYPE \\Server\Share\Folder\*.csv >> C:\Folder\ConcatenatedFile.csv

    Of course, before every run, you have to DELETE C:\Folder\ConcatenatedFile.csv

    The only issue is that if all files have headers, then it will be repeated in all files.

提交回复
热议问题