Page 1 of 1

-911(SQL dead lock) abend

Posted: Mon Apr 22, 2024 11:26 pm
by Ramesh_Mainframe
Hi,

Need a help here.

I have got -911(SQL dead lock) abend, how to get to know what are the resources were locked by this dead lock issue?

Re: -911(SQL dead lock) abend

Posted: Wed Apr 24, 2024 6:10 am
by zum13
Hello.

The available information about any SQL errors you encounter should be within the SQLCA (the SQL Communication Area). The subject of error handling has come up before and my general recommendation would be to use the DB2's error handling module DSNTIAR to help with message reporting. There's more information in this thread that should be of help: https://zmainframes.com/viewtopic.php?p ... iar#p34662

Re: -911(SQL dead lock) abend

Posted: Thu Apr 25, 2024 10:41 am
by Ramesh_Mainframe
Thanks zum13, this is really helpful. Is there a document which can help me to learn more about SQLCA?

Re: -911(SQL dead lock) abend

Posted: Thu Apr 25, 2024 4:10 pm
by zum13
The SQLCA field descriptions are here: https://www.ibm.com/docs/en/db2-for-zos ... ion-fields

The most useful (and most commonly used) thing in there is the SQLCODE. Over the years, I've found it's fairly rare to find an embedded SQL program which uses pretty much any of the other fields particularly as some of them are very conditional and the values can be difficult to interpret programatically. It's why DSNTIAR is an ideal solution to the error reporting problem. Not only is it DB2's own error reporting module, but you'll get a full error message and dump of the relevant SQLCA fields.