http://qs321.pair.com?node_id=884396


in reply to Re^2: maintaining a sorted structure
in thread maintaining a sorted structure

Using DB_File or BerkeleyDB you can easily tie a hash to a BTree, which offers the features that you want.