Ocasion receive "ORA-01403 no data found" in multi thread
Ocasion receive "ORA-01403 no data found" in multi thread
I am encountering a very strange problem using ODAC and have been looking for a solution for month and now became very frustrated, hope experts here can help.
I have a test multi thread program that will insert large amount of data into oracle 11g database, and occasionally I will receive "ORA-01403 no data found" error from the database. Below is the coding environments:
- Using Odac 650d11 pro
- Program compiled using RAD 2007
- A table with primary key with no trigger
- 50 threads, each thread to insert 1000 record, insert one record follow by another record
- insert statement is like 'insert into table1 (...) values (...)'
- most of the record is duplicated, so primary key violation will be occurred, but exception is catch and continue next record
- each insert statement will be follow by a select statement from another table
- The error occurred at insert statement, not select statement
Each time the program is finished, I will find a few "ORA-01403 no data found" errors out of many primary key violation error. I don't have any idea how on earth this no data found error comes from, I tried to use both TOraQuery & TOraSQL, result is the same. Can anyone help?
I have a test multi thread program that will insert large amount of data into oracle 11g database, and occasionally I will receive "ORA-01403 no data found" error from the database. Below is the coding environments:
- Using Odac 650d11 pro
- Program compiled using RAD 2007
- A table with primary key with no trigger
- 50 threads, each thread to insert 1000 record, insert one record follow by another record
- insert statement is like 'insert into table1 (...) values (...)'
- most of the record is duplicated, so primary key violation will be occurred, but exception is catch and continue next record
- each insert statement will be follow by a select statement from another table
- The error occurred at insert statement, not select statement
Each time the program is finished, I will find a few "ORA-01403 no data found" errors out of many primary key violation error. I don't have any idea how on earth this no data found error comes from, I tried to use both TOraQuery & TOraSQL, result is the same. Can anyone help?
another strange thing is, if taken out the select statement, the problem will not occur. And weird is, even with select statement, the error is occurred at the insert statement, not the select statement...
the select statement is something like 'select count(*) from table', so I don't think it will cause no data found error in any case.
the select statement is something like 'select count(*) from table', so I don't think it will cause no data found error in any case.
-
Challenger
- Devart Team
- Posts: 925
- Joined: Thu 17 Nov 2005 10:53
Yes, each thread is having their own TOraSession, so in my case, 50 connection is made to Oracle database. The problem wasn't occurred when using only few threads to perform data insert & select. So if using ODAC for enterprise project which required more threads, it doesn't meet our requirement anymore...
-
Challenger
- Devart Team
- Posts: 925
- Joined: Thu 17 Nov 2005 10:53