[CDBI] Make CDBI go fast

Perrin Harkins pharkins at gmail.com
Wed Mar 21 15:20:14 GMT 2007

On 3/21/07, Dave Howorth <dhoworth at mrc-lmb.cam.ac.uk> wrote:
> Don't you just need to run through the file once, updating the current
> first 11 at each step? I.e. compare each element against the current
> 11th and swap the element into the current 11 if appropriate.
> Potentially a lot less comparisons and exchanges than sorting the
> complete file.

Arguably still sorting, but yes, it would probably be faster to sort
into just 12 buckets.

The big win though is to make it so your sort can be handled by
indexes.  Once it goes to filesort on any large amount of data, it's
not going to be fast.

- Perrin

More information about the ClassDBI mailing list