ADSM-L

Re: DSMADMC SQL SELECT on Windows and SQLDISPLAYMODE

2001-02-20 11:24:32
Subject: Re: DSMADMC SQL SELECT on Windows and SQLDISPLAYMODE
From: Gerhard Rentschler <g.rentschler AT RUS.UNI-STUTTGART DOT DE>
Date: Tue, 20 Feb 2001 17:24:59 +0100
John,
you could try the -comma option on the dsmadmc command to get comma
separated output, which is a little bit better to process. The other option
would be to use ODBCdriver together with Excel, Access or even with
Activeperl.
Best regards
Gerhard

---
Gerhard Rentschler            email:g.rentschler AT rus.uni-stuttgart DOT de
Gerhard Rentschler            email:g.rentschler AT rus.uni-stuttgart DOT de
Regional Computing Center     tel.   ++49/711/685 5806
University of Stuttgart       fax:   ++49/711/682357
Allmandring 30a
D 70550
Stuttgart
Germany



> -----Original Message-----
> From: ADSM: Dist Stor Manager [mailto:ADSM-L AT VM.MARIST DOT EDU]On Behalf Of
> Talafous, John G.
> Sent: Saturday, February 03, 2001 8:00 PM
> To: ADSM-L AT VM.MARIST DOT EDU
> Subject: DSMADMC SQL SELECT on Windows and SQLDISPLAYMODE
>
>
> Greetings,
>   I run the TSM Administrative Command line interface on Windows. I use
> batch/command files to perform a number of functions. I could use
> some help
> in formatting the output of the SQL SELECT statement.
>   In this case, what I am trying to do is track tape drive utilization in
> order to better understand the impact of the TSM administrative schedules
> like storage pool backup and reclamation. So, I start with this SQL select
> statement:
>
> select date_time,message from actlog where msgno in (8337,8468)
>
> and the results look like this:
>
>          DATE_TIME     MESSAGE
> ------------------     ------------------
>         2001-01-02     ANR8337I 3590
>    00:02:54.000000      volume K20252
>                         mounted in drive
>                         3590DRIVE2
>                         (/dev/rmt2).
>
> Now I need to set SQLDISPLAYMODE wide and use the SELECT variable_name AS
> option to try to spread this out. So, I use redirection in Windows to pump
> multiple commands into DSMADMC to issue a SET SQL DISPLAYMODE WIDE command
> before the SQL SELECT command. I also change the SELECT to select
> MESSAGE AS
> and the results are:
>
> set sqldisplaymode wide
> select date_time,message as "Message_text_________________________" from
> actlog where msgno in (8337,8468)
>                             DATE_TIME: 2001-01-02 00:02:54.000000
> Message_text_________________________: ANR8337I 3590 volume K20252 mounted
> in
>                                         drive 3590DRIVE2 (/dev/rmt2).
>
> I must add that while this is running, not only is the output being
> redirected into a file but I am also seeing it scroll on the monitor.
> Well, this isn't quite right, so I use the -displaymode=table option on
> DSMADSC and I get:
>
> set sqldisplaymode wide
> select date_time,message as "Message_text_________________________" from
> actlog where msgno in (8337,8468)
>                  DATE_TIMEMessage_text_________________________
>
> ------------------------------------------------------------------
> ----------
> ------------------------------------------------------------------
> ----------
> ------------------------------------------------------------------
> ----------
> ------------------------------------------------
> 2001-01-02 00:02:54.000000ANR8337I 3590 volume K20252 mounted in drive
> 3590DRIVE2 (/dev/rmt2).
>
> A little bit better, but strange. Am I the only one that is
> struggling with
> this SQL formatting concept?
>
>   Is there a DSMADMC startup parameter like '-outfile' that is
> equivalent to
> SET SQLDISPLAYMODE WIDE? What are others doing to provide decent
> output from
> a DSMADMC SQL SELECT and Windows?"
>
> John G. Talafous              IS Technical Principal
> The Timken Company            Global Software Support
> P.O. Box 6927                 Data Management
> 1835 Dueber Ave. S.W.         Phone: (330)-471-3390
> Canton, Ohio USA  44706-0927  Fax  : (330)-471-4034
> talafous AT timken DOT com           http://www.timken.com
>
<Prev in Thread] Current Thread [Next in Thread>