=?iso-8859-1?Q?Andr=E9_Jos=E9_Guergolet?= <AGuergolet(at)compugraf(dot)com(dot)br> writes:
> INSERT INTO table1 (date, field2, field3) VALUES (now,'value2','value3');
> SELECT last_value FROM seq_table1;
You should never ever look directly at the sequence table (except
perhaps for manual debugging purposes). I think you may have confused
this with use of the lastval() function --- currval() or sometimes
lastval() are the appropriate way to get the last-assigned value.
regards, tom lane