Re: [GENERAL] Buggered Sequence - Mailing list pgsql-general

From Jesse Kipp
Subject Re: [GENERAL] Buggered Sequence
Date
Msg-id 38498310.7AE20E1C@revbox.com
Whole thread Raw
In response to Buggered Sequence  ("Jason C. Wells" <jcwells@u.washington.edu>)
Responses Re: [GENERAL] Buggered Sequence
List pgsql-general
Can you do:

drop sequence people_id_seq
create sequence people_id_seq start 44

?

jesse kipp



"Jason C. Wells" wrote:
>
> sequence_name|last_value|increment_by| max_value|min_value|cache_value|is_cycled|is_called
> -------------+----------+------------+----------+---------+-----------+---------+---------
> people_id_seq|         4|           1|2147483647|        1|          1|f        |t
> (1 row)
>
> After I screwed up a pgdump and restore I finally got my data back into
> the database. I have one little thing to fix. My sequence should be at
> last_value='44'.
>
> I tried to use update set last_value='44' but I wasn't allowed to change
> the sequence as jcwells or as the pgsql superuser. How can I fix my
> sequence?
>
> Thank You,      | http://students.washington.edu/jcwells/
> Jason Wells
>
> ************

pgsql-general by date:

Previous
From: "Jason C. Wells"
Date:
Subject: Buggered Sequence
Next
From: "Ross J. Reedstrom"
Date:
Subject: Re: [GENERAL] Buggered Sequence