Search code examples
postgresqlsequencerestartalter

Changing the sequence value of a PostgreSQL Sequence


How can I resequence the value start of a Sequence in PostgreSQL?


Solution

  • You can ALTER the sequence using the following code:

    ALTER SEQUENCE RESTART .

    You can go through the PostgreSQL sequence manuals at the below link:

    http://www.postgresql.org/docs/current/static/sql-altersequence.html