Board index » delphi » Sorting algorithm for three keys

Sorting algorithm for three keys

Hello,

I'm looking for a sorting algorithm which can sort on three keys.
Example:
First I want to sort on increasing lastname, then on increasing
firstname and finally on increasing age.

Already thanks,
                Marco

 

Re:Sorting algorithm for three keys


Quote
user wrote:

> Hello,

> I'm looking for a sorting algorithm which can sort on three keys.
> Example:
> First I want to sort on increasing lastname, then on increasing
> firstname and finally on increasing age.

> Already thanks,
>                 Marco

Hi Marco,

I have a QuickSort routine that sorts on 7 keys using 1 to 3 fields.

It uses DOS memory for arrays up to ~500k - the routines to allocate and
release memory are taken from SWAG.

It is too long to post, so I have emailed it to you. If you have any
questions, please email me.

Best Regards,

Michael R. Monett
mailto:a...@csolve.net

Other Threads