Board index » delphi » Sorting Text Files

Sorting Text Files

I would like to sort a large text file using a Delphi program.  The files
could approach 100 MB in size.  Does anyone have a component or sample code
for this?  Thanks!

Chuck

Read original science fiction and fantasy works at
http://moose.erie.net/~mudsox

 

Re:Sorting Text Files


Check out Martin Waldenburg's nice sorting object for sorting text files on
the DSP.

Cheers,

Gerald

In article <01bcac36$ab3dd960$46cc8ad0@ozzieserver>, "Charles E. Weindorf"

Quote
<mud...@erie.net> wrote:
>I would like to sort a large text file using a Delphi program.  The files
>could approach 100 MB in size.  Does anyone have a component or sample code
>for this?  Thanks!

>Chuck

>Read original science fiction and fantasy works at
>http://moose.erie.net/~mudsox

Re:Sorting Text Files


"Charles E. Weindorf" <mud...@erie.net> wrote:

Quote
>I would like to sort a large text file using a Delphi program.  The files
>could approach 100 MB in size.  Does anyone have a component or sample code
>for this?  Thanks!

Hi Chuck,

For a general purpose sort routine that handles variable length, text
and fixed length files, check out http://www.nitrosort.com.

NitroSort can sort 1 million 50 byte records in under a minute and a
half on a Pentium 120.  On the faster machines, this time is sub
minute.  For 1 million by 100 byte records you should see times from
1.5 minutes to 2.5 minutes depending on your processor.  

NitroSort is the only major commercial sort package that offers it's
library royalty free (See PCWeek Aug 4 review).  NitroSort was written
totally in Delphi and contains and easy interface to the general
sorting engine.  It also includes a GUI sorter for entering sort
scripts and testing your sorting statements.  NitroSort is actually
more than just a sorter, it also provides file manipulation and a host
of other features such as reformatting output records, qualifying
records to sort and of course, sorting.

In short, NitroSort is fast.  Your sorts sound like they would easily
run under a two minutes on a Pentium 120.  And maybe even sub 1 minute
on a Pentium 200+.

Jay Cole
My real address is @bgn.mindspring.com to prevent spam.

Other Threads