Program to split very large files by line count

C

Curious Joe

I have some files that are anywhere from 3GB to 9GB and I need to split
them down to a series of smaller files similar to what the "split"
command in linux can do. Unfortunately, I do not have access to a
linux machine right now. I have been told that a program could be
written in C/C++ that would do this very quickly.

Can anyone point me to a tutorial or how-to that will teach me to write
a quick program do accomplish this?

for example

split.exe <file.to.split> <output.filename.prefix>
<number.of.lines.per.file>

split.exe bigfile.txt bigfile_ 1000000

Thanks,

CJ
 
G

Gianni Mariani

Curious said:
I have some files that are anywhere from 3GB to 9GB and I need to split
them down to a series of smaller files similar to what the "split"
command in linux can do. Unfortunately, I do not have access to a
linux machine right now. I have been told that a program could be
written in C/C++ that would do this very quickly.

Can anyone point me to a tutorial or how-to that will teach me to write
a quick program do accomplish this?

for example

split.exe <file.to.split> <output.filename.prefix>
<number.of.lines.per.file>

split.exe bigfile.txt bigfile_ 1000000
Try installing mingw. It probably has the GNU splut command there.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,581
Members
45,056
Latest member
GlycogenSupporthealth

Latest Threads

Top