View previous topic :: View next topic
|
Author |
Message |
raam2smart
New User
Joined: 31 May 2007 Posts: 19 Location: Chennai
|
|
|
|
Hi,
What is the difference between -911 & -913 SQLCODES?
Thanks,
raam |
|
Back to top |
|
|
anandinmainframe
Active User
Joined: 31 May 2007 Posts: 171 Location: India
|
|
|
|
Raam,
-911 THE CURRENT UNIT OF WORK HAS BEEN ROLLED BACK DUE TO DEADLOCK OR TIMEOUT. REASON reason-code, TYPE OF RESOURCE resource-type, AND RESOURCE NAME
-913 UNSUCCESSFUL EXECUTION CAUSED BY DEADLOCK OR TIMEOUT. REASON CODE reason-code, TYPE OF RESOURCE resource-type, AND RESOURCE NAME resource-name |
|
Back to top |
|
|
Anuj Dhawan
Superior Member
Joined: 22 Apr 2006 Posts: 6250 Location: Mumbai, India
|
|
|
|
Don't you have access to documentations? |
|
Back to top |
|
|
raam2smart
New User
Joined: 31 May 2007 Posts: 19 Location: Chennai
|
|
|
|
I have access. But to me both look like one and the same. Thats why i posted this topic. |
|
Back to top |
|
|
raam2smart
New User
Joined: 31 May 2007 Posts: 19 Location: Chennai
|
|
|
|
Still i dont see any difference. Can any one explain? |
|
Back to top |
|
|
ashimer
Active Member
Joined: 13 Feb 2004 Posts: 551 Location: Bangalore
|
|
Back to top |
|
|
raam2smart
New User
Joined: 31 May 2007 Posts: 19 Location: Chennai
|
|
|
|
Thanks Ashimer!!! |
|
Back to top |
|
|
Raghu navaikulam
Active User
Joined: 27 Sep 2008 Posts: 193 Location: chennai
|
|
|
|
Hi raam2smart
In -911 a request is waiting for lock due to lack of locks in the system.
DB2 will allow the request to wait in the queue for a specific period of time(System specific). If within the specified time DB2 is unable to supply sufficient locks, then the request will be removed from the queue and sqlcode of -911 will be send to the requestor. This is known as "Timeout".
But in -913, two requests are waiting for another resource while holding one resource. Without getting the mutually held resource, both request can not proceed. This situation is called "Dead Lock". In both cases DB2 will supply Sqlcode -911/-913 with reason code and resource name. If you analyse reason code, you can see whether it is a "Timeout" or " Dead Lock".
If Reason code is 00C90088, then it is a "Dead Lock" and if reason code is 00C9008E, then it is a "Dead Lock"
In this case DB2 has to terminate any one of the request. Those request made more modification in the database within the current UOW will allow to continue and the other will be terminated. The terminated request will get sqlcode of -913 and will be Rolled back to a prior point in consistency.
Hope you may be able to get some idea about timeout and deadlock.
Regards
Raghu |
|
Back to top |
|
|
|