Skip to Main Content

Java Database Connectivity (JDBC)

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

preparedStatement.executeBatch() Not Working

843854Mar 21 2002 — edited Mar 21 2002
Hello,

I'm having a problem with the executeBatch() command. It seems that whenever I used it, my program just hangs up. What this program do is that it first read a text file and place it in an Array(txtArr[size]). Then it would also read the Database and place the contenent of the table in an array(tblArr[size]) as well. Each Array has at least 100,000 records. After this, the program would enter a loop to read txtArr[i] and check if it matches the tblArr. If the record from the textfile and the database matches, it would update the table using a preparedStatement.addBatch() command. After the said loop, it is then that the int[] cnt = preparedStatement.executeBatch() command is called. and that is when the Hanging part begins. Can you help me?

Thanks.
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Apr 18 2002
Added on Mar 21 2002
3 comments
1,616 views