13 apr 2007 kl. 15.48 skrev Yonik Seeley:
On 4/13/07, karl wettin <[EMAIL PROTECTED]> wrote:
It just hit me (and I did not consider it any further) that perhaps
one could store String.valueOf(theTitle.hashcode()) in an alternative
field and sort by that instead? It will not be 100% accurate, but in
most cases it will.
That would only mostly work for titles around 5 characters long,
right? It seems like after that, the correlation between hashCode and
sort order breaks down almost immediately since you lose the leftmost
hash bits.
That might be true, as I said, I didn't really think about it too
long. But some alternative hashCode could probably be implemented,
one that use all available bits in a string, rather than the 32 bit
limitation of an integer.
--
karl