Batch Script for Splitting Large TXT Files
Budget: $10 – $30 USD
I need a Windows-compatible batch script that can split a large text file, about 450KB with approximately 800,000 lines and into smaller files containing 50,000 lines each. The smaller files should be named sequentially as (SourceFileName)-01, (SourceFileName)-02, and so on. The new files will be placed in a different folder location. Source file will always be the same name/location. Will supply working source file.
Specific Requirements:
Source file varies but consistently has
- The first line of the original file should be included as a header in each of the split files.
- If there are any remaining lines that don't fit into a complete 20,000 line file, these should be placed into a separate, new file.
- I'd prefer something in Node JS or Powershell/CMD or another program I can edit with a txt editor to change file output line size, folder locations, etc.
Ideal Skills:
- Proficiency in writing batch scripts for Windows.
- Experience with file handling and manipulation in scripting.
- Attention to detail for ensuring headers are correctly added.
Specific Requirements:
Source file varies but consistently has
- The first line of the original file should be included as a header in each of the split files.
- If there are any remaining lines that don't fit into a complete 20,000 line file, these should be placed into a separate, new file.
- I'd prefer something in Node JS or Powershell/CMD or another program I can edit with a txt editor to change file output line size, folder locations, etc.
Ideal Skills:
- Proficiency in writing batch scripts for Windows.
- Experience with file handling and manipulation in scripting.
- Attention to detail for ensuring headers are correctly added.