Results 1 to 3 of 3
  1. #1
    Moderator chad_small's Avatar
    Join Date
    Dec 2002
    Location
    Gilbert, AZ
    Posts
    2,194
    Thanks
    1
    Thanked 25 Times in 24 Posts

    Default TSM 6.1 Timestamp Change

    So with the update to a DB2 structure the timestamp function has changed so that

    select * from actlog where (current_time-date_time) seconds <= 60 seconds

    Returns an error. So the new timestamp function is the following

    select * from actlog where timestampdiff(8, char(current_timestamp-date_time)) <= 24

    Where the following are the time functions for timestampdiff

    1 - Microseconds
    2 - Seconds
    4 - Minutes
    8 - Hours
    16 - Days ... and so forth

    The information on the changes to the SQL structure in TSM 6.x can be found here under Appendix B.
    Chad Small
    IBM Certified Deployment Professional
    chadsmal@gmail.com
    http://www.tsmadmin.com

  2. #2
    Member
    Join Date
    Oct 2005
    Posts
    57
    Thanks
    0
    Thanked 1 Time in 1 Post

    Default

    There were a good number of changes to the SQL engine, namely because DB2 handles most of the SQL now instead of the legacy database engine. More changes to the SQL syntax are documented in the link below.

    http://publib.boulder.ibm.com/infoce...md_select.html

  3. #3
    Member
    Join Date
    Oct 2005
    Posts
    57
    Thanks
    0
    Thanked 1 Time in 1 Post

    Default

    Also I recently was looking up how to do some date/time manipulation and found the following link very helpful. It gives a bunch of date/time calculation examples.

    http://www.ibm.com/developerworks/da.../0211yip3.html

Similar Threads

  1. Last modified timestamp
    By p305491 in forum TSM Reporting & Monitoring
    Replies: 3
    Last Post: 05-05-2010, 08:33 AM
  2. select statement with group by on timestamp
    By foxc71 in forum Scripting
    Replies: 1
    Last Post: 09-26-2008, 10:00 AM
  3. TSM setting timestamp after backup of GroupWise files - allowing trashcan deletion
    By Perry_Custer in forum Backup / Archive Discussion
    Replies: 1
    Last Post: 12-08-2006, 12:51 PM
  4. Timestamp script
    By ranjancom2000 in forum Scripting
    Replies: 14
    Last Post: 07-14-2006, 10:33 AM
  5. SQL Formating and manipulating timestamp columns
    By jykirsc in forum Scripting
    Replies: 1
    Last Post: 02-03-2005, 07:48 AM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •