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:[EMAIL PROTECTED]
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:[EMAIL PROTECTED]]On Behalf Of
> Talafous, John G.
> Sent: Saturday, February 03, 2001 8:00 PM
> To: [EMAIL PROTECTED]
> 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
> [EMAIL PROTECTED]           http://www.timken.com
>

Reply via email to