Skip site navigation (1) Skip section navigation (2)

Create on insert a unique random number

From: "Campbell, Lance" <lance(at)uiuc(dot)edu>
To: <pgsql-sql(at)postgresql(dot)org>
Subject: Create on insert a unique random number
Date: 2008-03-18 16:34:05
Message-ID: B10E6810AC2A2F4EA7550D072CDE8760CDDC32@SAB-FENWICK.sab.uiuc.edu (view raw or flat)
Thread:
Lists: pgsql-sql
When inserting a record is there a way to have postgres create a random
number for a field such that it is unique?

 

Thanks, 

 

Lance Campbell

Project Manager/Software Architect

Web Services at Public Affairs

University of Illinois

217.333.0382

http://webservices.uiuc.edu

 

Responses

pgsql-sql by date

Next:From: chester c youngDate: 2008-03-18 16:43:01
Subject: Re: Create on insert a unique random number
Previous:From: Chadwick HornDate: 2008-03-18 15:48:47
Subject: Re: postgres server crashes unexpectedly

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group