DB2 Z/os - Last used time



IBM's flagship relational database management system

DB2 Z/os - Last used time

Postby p19689 » Thu Aug 25, 2011 2:20 pm

Hi , I would like to identify all the Views that haven't been used for last 24 months . The application was coded in COBOL and runs on DB2 Z/os V9. What is the best way to approach this task.
p19689
 
Posts: 65
Joined: Fri Oct 01, 2010 1:13 pm
Has thanked: 0 time
Been thanked: 0 time

Re: DB2 Z/os - Last used time

Postby GuyC » Tue Aug 30, 2011 12:44 pm

select distinct BQUALIFIER,BNAME,DNAME from sysibm.syspackdep where btype = 'V'

gives you all packages where the views are used.
Unfortunately the column lastused in syspackage is not yet maintained in db2 v9.
Unless you have SMF history of monitor trace 7 there is no info in db2 when a package was last used.
I can explain it to you, but i can not understand it for you.
GuyC
 
Posts: 315
Joined: Tue Aug 11, 2009 3:23 pm
Has thanked: 1 time
Been thanked: 4 times

Re: DB2 Z/os - Last used time

Postby p19689 » Tue Aug 30, 2011 9:15 pm

Thanks GuyC, What you are suggesting is to go through the recently used packages and identify the views from them as there is no direct way to do that ?
p19689
 
Posts: 65
Joined: Fri Oct 01, 2010 1:13 pm
Has thanked: 0 time
Been thanked: 0 time

Re: DB2 Z/os - Last used time

Postby GuyC » Wed Aug 31, 2011 12:39 pm

yes
GuyC
 
Posts: 315
Joined: Tue Aug 11, 2009 3:23 pm
Has thanked: 1 time
Been thanked: 4 times


Return to DB2

 


  • Related topics
    Replies
    Views
    Last post