On Wed, Mar 07, 2007 at 23:20:12 +1100, Phillip Smith <fukawi2@iinet.net.au> wrote:
> If you actually need to know the value of N_GEN in your ASP application,
> you will need to query the database first and select the NEXTVAL from
> the sequence that the "serial" data type will create, then use that
> returned value in your insert - ie, DON'T exclude it from the insert,
> otherwise it will default to NEXTVAL again and return a different value.
In 8.2, you can also use the RETURNING clause to get those values.