From: Dmitry G. Mastrukov <dmitry@taurussoft.org>
To: Peter Eisentraut <peter_e@gmx.net>
Cc: Alex Pilosov <alex@pilosoft.com>
Cc: pgsql-hackers@postgresql.org
Subject: Re: Re: New data type: uniqueidentifier
Date: Wed, 04 Jul 2001 00:19:23 +0400
Message-ID: <3B4228CB.5060907@taurussoft.org> (raw)
References: <Pine.LNX.4.30.0107031732400.677-100000@peter.localdomain>
Peter Eisentraut wrote:
>Alex Pilosov writes:
>
>>Dmitry's stuff contains both datatype (uniqueidentifier), a function to
>>generate a new object of that type (newid), and a set of functions to
>>implement comparison operators for that type.
>>
>>I don't see anything wrong with that setup, but maybe I'm still missing
>>something?
>>
>
>It would be much simpler if you stored the unique id in varchar or text.
>
Are you sure varchar comparision will be quickly than current
implementation? Next, varchar will need 36 byte, uniqueidentifier takes
16. Next, indexing - IMHO current stuff more suitable for indexes. Some
time ago I saw some stuff which deals with uniqueidentifiers for
Interbase. It uses your scheme with chars. But it strip "-" from string
and reverts it to efficiently use indexes (uid sometimes uses
MAC-address as part of itself, so MAC should go first in string). Weird
scheme for me!
regards,
Dmitry
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-hackers@postgresql.org
Cc: dmitry@taurussoft.org, peter_e@gmx.net, alex@pilosoft.com
Subject: Re: Re: New data type: uniqueidentifier
In-Reply-To: <3B4228CB.5060907@taurussoft.org>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox