Re: [SQL] Last serial number inserted

2000-10-17 Thread Josh Berkus
Eduardo, Use the curval(serial) function. For more information, look in the online docs under the name of that function. nextval(), curval() are wonderful things! -Josh Berkus -- __AGLIO DATABASE SOLUTIONS___

[SQL] Last serial number inserted

2000-10-17 Thread Eduardo
How can I get the last id ( serial number ) inserted. My C code is : res = PQexec(conn,"insert into table1 (field1) values ('value1')"); table1: id SERIAL, field1 VARCHAR(10) Thanks Eduardo K