Subject Re: Some benchmarks about 'Order by' - temporary indexes?...
Author Adam
> > This is known weak of our sorting algoritm. In-memory we do move
> > of pointers but on disk we move whole records. You can learn sort.cpp
> > to be sure
> Are you sure that's a weakness? True it makes sorting slower, but
> it avoids re-reading the records in sorted order which is much slower.
> We should only be carrying the fields that were requested, so the
> size of the record doesn't matter, only the number and size of the
> fields in the select list.

Hi Ann (+others),

The penalty for reading records in 'out of storage' order is purely a
'hard disk thing'. Reading in storage order is beneficial for hard
drive technologies, because once the read head is in position, each
'next block' of data is going to be located with the time. When
reading from a disk in sorted order, you need to wait

1) For the head to move into position

(and when that is done)

2) The piece of the platter with the data stored arrives under the head.

For other storage technologies like solid state, there is no
difference in speed between reading the data in the storage order and
reading the data in the order you want it returned.

I am not about to claim that hard drives are dead, they will always
have a niche, but in the next 2 years we will see a significant number
of new computers (mostly laptops to begin with) switch to solid state
because of price (for small quantities), reliability and power

This change will happen when:

1) The storage size is 'high enough'
2) The price is 'cheap enough'
3) People become confident that write cycle issues are resolved.

In 5 years time, you won't get a hard disk from Dell, HP or Apple
unless you choose a special box on the order form. Should we perhaps
be considering how to make the most out of different storage
technologies, rather than limiting ourselves to the restrictions of a


--Sorry if a similar worded post from me is duplicated, my Newsreader
doesn't appear to be working properly.