Problem with sequence table - Mailing list pgsql-general

From David Goodenough
Subject Problem with sequence table
Date
Msg-id 200602081240.39258.david.goodenough@btconnect.com
Whole thread Raw
Responses Re: Problem with sequence table  (Richard Huxton <dev@archonet.com>)
List pgsql-general
I have a DB (PostgreSQL of course) which has in the definition of one of
its tables that the default is nextval(public.rr_id_seq'::text).  When I look
in the sequence I see that the "last_value" column is 40, but the largest
value in the relevant column is 45.  I tried using the SQL update command
to update this value but it would not let me.  How do I get rr_id_seq in step
with the data in the table?

David

pgsql-general by date:

Previous
From: Richard Huxton
Date:
Subject: Re: loading pg_description ... FATAL: duplicate key violates
Next
From: Richard Huxton
Date:
Subject: Re: Problem with sequence table