Re: auto_increment - Mailing list pgsql-sql

From Muhyiddin A.M Hayat
Subject Re: auto_increment
Date
Msg-id 002201c37f54$29608e40$1f00a8c0@middinkcomp
Whole thread Raw
In response to auto_increment  ("Muhyiddin A.M Hayat" <middink@indo.net.id>)
Responses Re: auto_increment
Re: auto_increment
List pgsql-sql
Ok, but if i do rollback, the auto_increment don't roolback.
How to use nextval(), currval() and setval() functions.
 
----- Original Message -----
Sent: Saturday, September 20, 2003 2:15 PM
Subject: RE: [SQL] auto_increment

Create table tablename(

  id serial,

  ……..

);

 

Serial type is integer and autoincrement

When you create  this table creates automatic sequence tablename_id_seq

Stored sequence last value;

Try execSQL : select * from tablename_id_seq;

 

My english is very very little and bad

 

pgsql-sql by date:

Previous
From: shyamperi@davlin.co.in
Date:
Subject: Re: Error with functions
Next
From: Richard Huxton
Date:
Subject: Re: auto_increment