Hi,
I have a job where i am generating the sequence number through KeyMgtGetNextValueConcurrent('N') and storing in unique id.
The job.invocation id aborted with ORA-00001: unique constraint violation on the unique id index.
When i check the current max value of the database and the value in SDKSequences file, the SDKSequences file contains one value greater than the database value. Looks like no issue with the sequence number generation.
I am wondering what could be the reason for this unique constraint violation.
Sequence number issue
Moderators: chulett, rschirm, roy
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
The key in SDKSequences obviously got out of synchronization with the key of the Oracle table, or perhaps you are not using the correct sequence name in your KeyMgtGetNextKey() call.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Re: Sequence number issue
So are we, and it's not really a question we can answer for you other than to state what Ray did. The routine has no clue if some other process has already issued a given number or not, it just assures that it only hands a number out once.dnat wrote:I am wondering what could be the reason for this unique constraint violation.
You'll need to do the investigation, find out where the records you collided with came from.
-craig
"You can never have too many knives" -- Logan Nine Fingers
"You can never have too many knives" -- Logan Nine Fingers