pgadmin4 icon indicating copy to clipboard operation
pgadmin4 copied to clipboard

Improve setval for sequences (RM #5130)

Open dpage opened this issue 5 years ago • 1 comments

Issue migrated from Redmine: https://redmine.postgresql.org/issues/5130 Originally created by Jorge Gustavo Rocha at 2020-01-28 23:57:50 UTC.

We can set the sequence value back to 1 using the interface. But if we set the sequence to 1, it will provide the value 2 next time. Using the interface, there is no way to have the sequence back to 1.

It is different: SELECT setval('foo', 1); or SELECT setval('foo', 1, false);

When the user sets the sequence to a given value n, pgAdmin could do: ALTER SEQUENCE foo RESTART WITH n; or SELECT setval('foo', n, false);

dpage avatar Jan 28 '20 23:01 dpage

Comment migrated from Redmine: https://redmine.postgresql.org/issues/5130#note-1 Originally created by Akshay Joshi at 2020-01-31 11:23:32 UTC.

Redmine ticket header update:

Name Old Value New Value
Sprint changed Ready

dpage avatar Jan 31 '20 11:01 dpage

The issue was fixed and verified on snapshot build.

pravesh-sharma avatar Jan 29 '25 06:01 pravesh-sharma