I want to find the failed sql statement in application.
run command 'db2 get snapshot for all applications'
get below information
Application name = db2wlmd
Dynamic SQL statements attempted = 18
Static SQL statements attempted = 7
Failed statement operations = 3
I want to find these 3 failed sql statements. Would you please let me know how? Thanks.
This topic has been locked.
2 replies Latest Post - 2013-03-28T07:29:03Z by quchl
Pinned topic How to find the failed sql statement in application
Answered question This question has been answered.
Unanswered question This question has not been answered yet.
Updated on 2013-03-28T07:29:03Z at 2013-03-28T07:29:03Z by quchl
nivanov1 100000H9H7231 PostsACCEPTED ANSWER
Re: How to find the failed sql statement in application2013-03-27T15:18:04Z in response to quchlNot sure why you would want to do that. db2wlmd is an internal DB2 process -- the Workload Manager.
You can create an event monitor for statements and filter the output for the issuing application name and the statement SQLCODE (returned as a part of the SQLCA element).
quchl 270004HEVH3 PostsACCEPTED ANSWER
Re: How to find the failed sql statement in application2013-03-28T07:29:03Z in response to nivanov1Thanks nivanov1. Actually I just take the db2wlmd as the example.
Is there any select command to get the failed SQL statement? like select * from table function or from Administrative view