Tags: command, connection, database, db2, executed, mysql, oracle, snapshot, sql

How to get the last executed SQL command for each DB connection

On Database » DB2

575 words with 1 Comments; publish: Fri, 07 Dec 2007 18:04:00 GMT; (25032.23, « »)

Hello,

I am using DB2 8.2. And I am wondering how to get the last executed SQL command for each DB connection. I tried to get snapshot, but it seems that no such information can be retrieved from DB2 snapshot. Please advise if any related mechanism available. Thanks a lot.

All Comments

Leave a comment...

  • 1 Comments
    • Look at the SNAPSHOT_STATEMENT function. You can find out about it by looking at the online documentation located at:

      http://publib.boulder.ibm.com/infocenter/db2luw/v8//index.jsp

      Look in the Reference->SQL->Functions->Table Functions

      HTH

      Andy

      #1; Tue, 11 Dec 2007 18:18:00 GMT