All Forums Database
Sandeepyadav 52 posts Joined 09/13
14 Oct 2014
Sessions are getting block

Hi All,
 
we are facing an issue regarding multiple sessions are inserting data in a table that’s why other sessions are getting block because they also try to insert error record in the same table. This is a error table and each job insert data in it when it find any error records. Jobs are getting delay because jobs need to wait till it gets write lock on error table.
 
Any suggestion to resolve this issue
 
Thanks -Sandeep.

Thanks, -Sandeep.
Raja_KT 1246 posts Joined 07/09
14 Oct 2014

You have not given infos of utilities ...... :)
Looks like you are using the same DBs for error, log..... tables?
 

Raja K Thaw
My wiki: http://en.wikipedia.org/wiki/User:Kt_raj1
Street Children suffer not by their fault. We can help them if we want.

Sandeepyadav 52 posts Joined 09/13
14 Oct 2014

Thanks Raja for your reply.
 
well its a job that trigger using datastage. Each job check records from this error table if it find any records then it move it into this table.
lets say three job are running then all jobs will check data in error table first if job data also exist in error table then those recors that are common will move to error table. If all jobs find some common records the all will try to insert in same table that results to blocking.
 
Thanks -Sandeep.

Thanks, -Sandeep.

Raja_KT 1246 posts Joined 07/09
14 Oct 2014

Without seeing the code in DS, can't say much. However, you can think of doing a lock, to avoid deadlock or use different DB if possible for error, log.....

Raja K Thaw
My wiki: http://en.wikipedia.org/wiki/User:Kt_raj1
Street Children suffer not by their fault. We can help them if we want.

fnewbrough 17 posts Joined 05/11
15 Oct 2014

You can achive write concurrency on a table provided that the row hash locks do not overlap otherwise you will be blocked which is probably what is happening in your case. 

You must sign in to leave a comment.