Here is one of good article:
[Db2] Simple test case shell script for db2audit instance and database level auditing
https://www.ibm.com/support/pages/node/1075779
Excerpt of the SQLs in the article *
db2 -v "drop db $DBNAME"
db2 -v "create db $DBNAME"
db2 -v "connect to $DBNAME"
db2 -v "connect to $DBNAME user hoge using hoge"
Excerpt of the resutl of instance level auditing from that article *
STATUS DATABASE USERID
----------- -------- ----------
0 DB1 db2inst1
0 DB1 db2inst1
0 DB1 db2inst1
0 DB1 db2inst1
-30082 DB1 hoge
-----
Much more information on it! So, it might be recommended to review this article.
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…