Re: (un)grouping question - Mailing list pgsql-general

From Reece Hart
Subject Re: (un)grouping question
Date
Msg-id 1200950458.7144.47.camel@snafu
Whole thread Raw
In response to Re: (un)grouping question  (Andrei Kovalevski <andyk@commandprompt.com>)
List pgsql-general
On Mon, 2008-01-21 at 22:05 +0200, Andrei Kovalevski wrote:
> How can you garantee that "somevalue + random()" won't duplicate other
> unique values in this column? ;)

Like the inane memo from the boss says, "expect the unexpected" and
"tell me all the unpredictable issues that will happen".

If uid is unique then something like
=> select uid,somevalue,somevalue||'-'||uid from mytable
is much better.

-Reece

--
Reece Hart, http://harts.net/reece/, GPG:0x25EC91A0


pgsql-general by date:

Previous
From: "Merlin Moncure"
Date:
Subject: Re: US Military / Government Approval
Next
From: "Daniel Verite"
Date:
Subject: Re: Graphics