----- Original Message -----
From: "Ingram, Bryan" <BIngram@sixtyfootspider.com>
To: "Ingram, Bryan" <BIngram@sixtyfootspider.com>; <mig@utdt.edu>
Cc: <pgsql-sql@postgresql.org>
Sent: Tuesday, April 11, 2000 9:57 PM
Subject: RE: [SQL] Threaded Records in SQL: Advice Needed
> In reference to the ascii/numeric ordering problem ..
>
> But first let me say ..if someone knows of a way to get ascii values to
> order as if they were numerics ..please let me in on the secret ..
>
> Instead of using numbers, if letters were used the ordering would be
> correct.
>
> The id string would become something like: A/A/A for the 1st reply to the
> 1st reply of the 1st root message.
>
> This will work fine for threads with relatively few replies on the same
> level. For instance, the number 100 would take only 4 characters to
encode,
> however, the number 1000 would need 39 characters to encode.
More efficient to use letters as numbers in base 26? Then for up to 676
replies per level you need only 2 letters. If you allowed 3, you'd have
some headroom.
----------------------------------------------------------------
Moray.McConnachie@computing-services.oxford.ac.uk