Dennis Gearon <gearond@fireserve.net> writes:
> Oliver Elphick wrote:
>
> >You cannot use currval() until you have used nextval() on the same
> >sequence in the same session.
> Why is that, anyway, and why should it be?
Because that's what currval() does. It doesn't have anything to do
with sequence values in other sessions. It gives you the last value
*you* got for thee sequence, so if you haven't called nextval() yet
you should and do get an error.
Maybe it should have been called lastval(), but that could be a bit
misleading too...
-Doug