Re: problem wit hsequence as primary key

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Rob Brown-Bayliss <rob(at)zoism(dot)org>
Cc: PostgreSQL General List <pgsql-general(at)postgresql(dot)org>
Subject: Re: problem wit hsequence as primary key
Date: 2002-07-26 15:20:49
Message-ID: 25665.1027696849@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Rob Brown-Bayliss <rob(at)zoism(dot)org> writes:
> sequence_number := to_char(nextval(''location_seq''),''99999MI'');

> The location_seq is up to 100005 at the moment so how am I getting
> duplicate primary keys?

Time for more 9's in that to_char format, perhaps?

regards, tom lane

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Tom Lane 2002-07-26 15:23:46 Re: Execute vacuum postgresql crash
Previous Message Don Isgitt 2002-07-26 15:09:36 Re: Bad HTML in Mail List Archives