in reply to Sorting data that don't fit in memory
For sorting more data than you have room for I recommend
tieing a hash through DB_File to a BTree. That
allows you to just put items into the hash and then pull
them out in sorted order.
There is some overhead to the structure, so without large file support this will usually only suffice for a little over a GB of data. With large file support and sufficient disk, you can handle many terabytes efficiently.
In Section
Seekers of Perl Wisdom