1. Forum Rules (PLEASE CLICK HERE TO READ BEFORE POSTING) Click the link to access ADSM.ORG Acceptable Use Policy and forum rules which should be observed when using this website. Violators may be banned from this website. This message will disappear after you have made at least 12 posts. Thank you for your cooperation.

Pulling Archive Date via a script.

Discussion in 'TSM Installation, Upgrade and Configuration' started by PastaFazole, Sep 15, 2011.

  1. PastaFazole

    PastaFazole New Member

    Joined:
    Apr 22, 2010
    Messages:
    3
    Likes Received:
    0
    Currently, I run the following script to find out about my backups:

    select node_name, date(backup_end)as BkupDate, filespace_name from filespaces order by BkupDate asc

    But I want to add the date for each archive job to this command. However, I don't know the code to plug in to do this. I have tried using my existing script as a guide, but my attempts fail:

    upd script checkbackup line=1 "select node_name, date(backup_end)as BkupDate, Archive_Date, filespace_name from filespaces order by BkupDate asc" ANR2004E Missing value for keyword parameter - select node_name, date(backup_end)as BkupDate, Archive_Date, filespace_name from filespaces order by
    BkupDate asc.
    ANS8001I Return code 3.

    Where should I be looking? The administrative reference guide doesn't seem to have what I want.

    Thanks,
    Pasta Fazole
     
  2.  
  3. tariq.kaifi

    tariq.kaifi Member

    Joined:
    Nov 1, 2009
    Messages:
    316
    Likes Received:
    22
    Location:
    India
    Filespace table do not have "Archive_Date" column.
     
  4. PastaFazole

    PastaFazole New Member

    Joined:
    Apr 22, 2010
    Messages:
    3
    Likes Received:
    0
    Thanks for that information. Can you tell me how to see for myself what the filespace table has and doesn't have. I believe what you say is true, but I'm trying to learn more about scripting and TSM.
     
  5. moon-buddy

    moon-buddy Moderator

    Joined:
    Aug 24, 2005
    Messages:
    6,079
    Likes Received:
    269
    Occupation:
    Electronics Engineer, Security Professional
    Location:
    Somewhere in the US
    Here are the fields for filespaces:

    NODE_NAME
    FILESPACE_NAME
    FILESPACE_ID
    FILESPACE_TYPE
    CAPACITY
    PCT_UTIL
    BACKUP_START
    BACKUP_END
    DELETE_OCCURRED
    UNICODE_FILESPACE
    FILESPACE_HEXNAME:
     
  6. cjhood

    cjhood Moderator

    Joined:
    Dec 11, 2007
    Messages:
    322
    Likes Received:
    10
    Occupation:
    Storage Administrator - TSM/SAN
    Location:
    Brisbane, Australia
    To find the columns in a table you can run this select:

    select * from syscat.columns where tabname='<table_name>' order by colno

    eg: select * from syscat.columns where tabname='FILESPACES' order by colno

    The 'order by' part isn't required. To just get the column names, replace the '*' with 'colname'
     
: archive, scripts

Share This Page