By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
454,605 Members | 1,483 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 454,605 IT Pros & Developers. It's quick & easy.

Program to split very large files by line count

P: n/a
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

Nov 10 '06 #1
Share this Question
Share on Google+
2 Replies


P: n/a
Curious Joe wrote:
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.
Nov 10 '06 #2

P: n/a

Gianni Mariani wrote in message
<45**********************@per-qv1-newsreader-01.iinet.net.au>...
>Curious Joe wrote:
>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.
"split.exe" is in 'Msys'.

--
Bob R
POVrookie
Nov 10 '06 #3

This discussion thread is closed

Replies have been disabled for this discussion.