Re: Sequence reset

From: Raymond O'Donnell <rod(at)iol(dot)ie>
To: "SUNDAY A(dot) OLUTAYO" <olutayo(at)sadeeb(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Sequence reset
Date: 2010-08-23 10:14:20
Message-ID: 4C7249FC.2030001@iol.ie
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On 23/08/2010 11:04, SUNDAY A. OLUTAYO wrote:
> How can I reset a sequence column due to deletion of some rolls?

You can use the setval() function to set its value to whatever you like:

http://www.postgresql.org/docs/8.4/static/functions-sequence.html

HTH

Ray.

--
Raymond O'Donnell :: Galway :: Ireland
rod(at)iol(dot)ie

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Magnus Hagander 2010-08-23 10:15:28 Re: disappearing data
Previous Message Garry Saddington 2010-08-23 10:12:26 disappearing data