Re: Threaded Records in SQL: Advice Needed - Mailing list pgsql-sql

From Moray McConnachie
Subject Re: Threaded Records in SQL: Advice Needed
Date
Msg-id 008501bfa45b$8162d3a0$760e01a3@oucs.ox.ac.uk
Whole thread Raw
In response to RE: Threaded Records in SQL: Advice Needed  ("Ingram, Bryan" <BIngram@sixtyfootspider.com>)
List pgsql-sql
----- 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



pgsql-sql by date:

Previous
From: Peter Stamfest
Date:
Subject: Re: DBD::ODBC for Linux
Next
From: Fabrice Scemama
Date:
Subject: Re: DBD::ODBC for Linux