Re: auto_increment - Mailing list pgsql-sql

From Oliver Elphick
Subject Re: auto_increment
Date
Msg-id 1064038995.5359.70.camel@linda.lfix.co.uk
Whole thread Raw
In response to auto_increment  ("Muhyiddin A.M Hayat" <middink@indo.net.id>)
Responses Re: auto_increment  (Martin Marques <martin@bugs.unl.edu.ar>)
Re: auto_increment  (sad <sad@bankir.ru>)
List pgsql-sql
On Sat, 2003-09-20 at 06:10, Muhyiddin A.M Hayat wrote:
> How to Create auto_increment field in PostreSQL.
> Can I create them using Trigger.

Use the SERIAL datatype.  See also the functions nextval(), currval()
and setval().

-- 
Oliver Elphick                                Oliver.Elphick@lfix.co.uk
Isle of Wight, UK                             http://www.lfix.co.uk/oliver
GPG: 1024D/3E1D0C1C: CA12 09E0 E8D5 8870 5839  932A 614D 4C34 3E1D 0C1C
========================================   "But my God shall supply all your need according to his     riches in glory
byChrist Jesus."     Philippians 4:19
 



pgsql-sql by date:

Previous
From: "Muhyiddin A.M Hayat"
Date:
Subject: auto_increment
Next
From: shyamperi@davlin.co.in
Date:
Subject: Error with functions