ADSM-L

[ADSM-L] Zero not less than 30!

2007-08-14 02:42:32
Subject: [ADSM-L] Zero not less than 30!
From: Steve Harris <steve AT STEVENHARRIS DOT INFO>
To: ADSM-L AT VM.MARIST DOT EDU
Date: Tue, 14 Aug 2007 02:40:36 -0400
Hi All,

Just got embarrassed when I relied on an sql query that thinks that zero is not less than 30.
tsm: GFC2>select node_name, date(lastacc_time), current date-
date(lastacc_time) from nodes where current date -
date(lastacc_time) < 30 days
NODE_NAME              Unnamed[2]     Unnamed[3]
------------------     ----------     ----------
AUBHDCAP001            2007-08-13              1
AUBHDCAP02             2007-08-13              1
AUBHDCAP03             2007-08-13              1
AUCAMPAP01             2007-08-13              1
AUCAMPAP03             2007-08-13              1
AUCAMPAP09             2007-08-13              1
AUCAMPSP04             2007-08-13              1
GFLAUNRYA02            2007-08-13              1
GFLAUNRYA11            2007-07-19             26
GFLAUNRYA14            2007-08-13              1
GFLAUNRYF10            2007-07-16             29
GFLAUNRYG01            2007-08-13              1
GFLAUNRYG02            2007-08-13              1
LNAPP100               2007-08-13              1
LNMAIL100              2007-08-13              1
MBAAUNRYA01            2007-08-13              1
POGO                   2007-08-12              2
TIVDB100               2007-08-13              1
TIVTMR100              2007-08-13              1

But wait - there's more! add a clause where the dates are equal and we get..

tsm: GFC2>select node_name, date(lastacc_time), current date- date(lastacc_time) from nodes where current date - date(lastacc_time) < 30 days or date( lastacc_time)=current date
NODE_NAME              Unnamed[2]     Unnamed[3]
------------------     ----------     ----------
AUBHDCAP001            2007-08-13              1
AUBHDCAP02             2007-08-13              1
AUBHDCAP03             2007-08-13              1
AUBHDCDP01             2007-08-14              0
AUBHDCDP02             2007-08-14              0
AUBHDCDT01             2007-08-14              0
AUBHDCSP01             2007-08-14              0
AUBHDCSP02             2007-08-14              0
AUBHDCSP05             2007-08-14              0
AUBHDCSP06             2007-08-14              0
AUBHDCSP08             2007-08-14              0
AUBHDCSP08_SQL         2007-08-14              0
AUBHDCSP09             2007-08-14              0
AUBHDCST01             2007-08-14              0
AUCAMPAP01             2007-08-13              1
AUCAMPAP03             2007-08-13              1
AUCAMPAP05             2007-08-14              0
AUCAMPAP09             2007-08-13              1
AUCAMPAP12             2007-08-14              0
AUCAMPSP04             2007-08-13              1
AUSTKLDP02             2007-08-14              0
GFLAUNRYA02            2007-08-13              1
GFLAUNRYA11            2007-07-19             26
GFLAUNRYA14            2007-08-13              1
GFLAUNRYA19            2007-08-14              0
GFLAUNRYF10            2007-07-16             29
GFLAUNRYG01            2007-08-13              1
GFLAUNRYG02            2007-08-13              1
ITSM100                2007-08-14              0
LNAPP100               2007-08-13              1
LNAPP100_AUAN01        2007-08-14              0
LNAPP100_AUAN02        2007-08-14              0
LNAPP100_AUAN03        2007-08-14              0
LNAPP100_AUAN04        2007-08-14              0
LNAPP100_AUAN05        2007-08-14              0
LNMAIL100              2007-08-13              1
LNMAIL100_AUHN01       2007-08-14              0
LNMAIL100_AUMN02       2007-08-14              0
LNMAIL100_AUMN03       2007-08-14              0
MBAAUNRYA01            2007-08-13              1
MFG011                 2007-08-14              0
MFG100                 2007-08-14              0
MFG100_ORA             2007-08-14              0
POGO                   2007-08-12              2
TIVDB100               2007-08-13              1
TIVTMR100              2007-08-13              1


This has happened on AIX tsm 5.1 and 5.3 - would some kind soul like to try 5.4 and see whether there has been an improvement?
Thanks

Steve Harris
TSM Admin
Sydney Australia

<Prev in Thread] Current Thread [Next in Thread>