Re: About auto_increment - Mailing list pgsql-general

From Raymond O'Donnell
Subject Re: About auto_increment
Date
Msg-id 459A8020.22087.93F457@rod.iol.ie
Whole thread Raw
In response to About auto_increment  (Yesh <rengesh2k3@yahoo.co.in>)
List pgsql-general
On 1 Jan 2007 at 21:21, Yesh wrote:

> I need to know how to increment a primary key field automatically in
> run time.

Use type SERIAL as your primary key - here is the relevant page in
the docs:

http://www.postgresql.org/docs/8.2/static/datatype-
numeric.html#DATATYPE-SERIAL

HTH,

--Ray.


----------------------------------------------------------------------

Raymond O'Donnell
Director of Music, Galway Cathedral, Galway, Ireland
rod@iol.ie
----------------------------------------------------------------------



pgsql-general by date:

Previous
From: Richard Huxton
Date:
Subject: Re: About auto_increment
Next
From: "Raymond O'Donnell"
Date:
Subject: Re: Geographical redundancy