How do I set isolation level in DB2?

You are a DBA and you want your users to use an isolation level of UR who are doing adhoc queries or typing SQLs using DB2 CLP or some form of the applications. By using DB2 CLP Use SET CURRENT ISOLATION LEVEL command db2 connect to sample db2 set current isolation...

How do I set special registers in DB2 for audit?

Through a application server where you open dedicated connections to database, you get information about your SQL using applications server user-id only. How do you tie those information back to the end user who initiated the transaction? One option is to use DB2...

LAST_DAY, FIRST_DAY in DB2

LAST_DAY(SYSDATE) ==> values (current date + 1 month) – day(current date +1 month) days FIRST_DAY(SYSDATE) ==> values (current date – day(current date + 1 month) days) + 1 DAY

Get index space usage for a table

How do you get index space usage by a table? DB2 provides a Table function ADMIN_GET_TAB_INFO to retrieve information about a table. For example – To find index space used by a non-partition table’s indexes, you can use following SQL: SELECT...