Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: How to get the last insert id
Norbert Pürringer wrote:
> Hello,
>
> does anyone know how to get the id of the last inserted dataset in
> Oracle?
>
> SQL Server does have Scope_Idendity, MySQL has LastInsertID
>
> Thanks,
> Norbert
It is impossible to know unless you have a timestamp column for that purpose or your ID generation mechanism has forced serialization. My comment assumes you are not using Oracle as a single-user system.
-- Daniel A. Morgan University of Washington damorgan_at_x.washington.edu (replace x with u to respond) Puget Sound Oracle Users Group www.psoug.orgReceived on Fri Sep 07 2007 - 11:44:43 CDT
![]() |
![]() |