• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

How to handle parallel or concurrent updates

 
sourabh jaiswal
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi!,

I am doing concurrent updates on same table with java.

I have 2 cron jobs set in linux. Requirement is to execute them at same time. Both cron jobs run java code(JDBC) to update same table. I would like to know how can I perform this without hitting performance and locking table.
I am updating 50000 to 2lakh rows.

The database I am using is DB2.

Thanks,
 
Jeanne Boyarsky
author & internet detective
Marshal
Posts: 34071
331
Eclipse IDE Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You'll need to elaborate more on the requirement. How big is the table? Do the cron jobs do the exact same thing or do they access different rows? What kind of update query is it? What database are you using?
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic