Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Auto-increment sequence
Hi,
I wrote a sequence to generate unique ID numbers for a table, along with a before insert trigger. I'm also writing an application in Delphi to access this database. I'm using 9i and Delphi 5.
My problem is this: When I run the insert procedure, and come up against a not null violation, the sequence increments anyway, and the next time I successfully insert a record, the previous number is skipped. How do I avoid this problem and keep the number in sequence?
Thanks,
Mike Trozzo
Received on Wed Nov 13 2002 - 17:26:06 CST
![]() |
![]() |