Re: Sequence bug - Mailing list pgadmin-hackers

From Andreas Pflug
Subject Re: Sequence bug
Date
Msg-id 4177BF8D.4010309@pse-consulting.de
Whole thread Raw
In response to Re: Sequence bug  ("Dave Page" <dpage@vale-housing.co.uk>)
List pgadmin-hackers
Dave Page wrote:

>
> Hmm, it works OK (thanks), but not as you would expect. With setval's
> third arg = false, you can set the sequence value to 1, which is
> displayed as expected as the 'Current Value', but then a 'SELECT
> nextval()' also returns 1 which is not what you would expect (especially
> if you are not the same user, or you forgot what you did earlier).

But this is consistent with ALTER SEQUENCE ... RESTART ...; I just checked.

> Maybe it's better not to try to allow resetting to 0 with 7,3?

Why not? 0 sounds like a legal int value to me...

Regards,
Andreas

pgadmin-hackers by date:

Previous
From: "Dave Page"
Date:
Subject: Re: Sequence bug
Next
From: "Dave Page"
Date:
Subject: Re: Sequence bug