Use this command to display information about scripts.
You can use this command in conjunction with the DEFINE SCRIPT command to create a new script using the contents from another script.
.-*-----------. >>-Query SCRipt--+-------------+--------------------------------> '-script_name-' .-FORMAT--=--Standard------------------------------. >--+--------------------------------------------------+-------->< '-FORMAT--=--+-Standard--------------------------+-' +-Lines-----------------------------+ +-Detailed--------------------------+ '-Raw--+--------------------------+-' '-Outputfile--=--file_name-'
If no output file is specified, the Tivoli® Storage Manager server outputs the "query script" with "format=raw" to the console.
query script *
Name Description
--------------- ----------------------------------------------------
QCOLS Display columns for a specified SQL table
QSAMPLE Sample SQL Query
EXAMPLE Backup the store pools and database when no sessions
query script q_authority format=lines
Name Line Command
Number
---------- ------ -------------------------------------------------
Q_AUTHORITY 1 /* ------------------------------------------*/
5 /* Script Name: Q_AUTHORITY */
10 /* Description: Display administrators that */
15 /* have the authority to issue */
20 /* commands requiring a */
25 /* specific privilege. */
30 /* Parameter 1: privilege name - in the form */
35 /* x_priv - EX. policy_priv */
40 /* Example: run q_authority storage_priv */
45 /* ------------------------------------------*/
50 select admin_name from admins where -
55 upper(system_priv) <> 'NO' or -
60 upper($1) <> 'NO'
query script engdev format=raw outputfile=my.script
define script agadm file=my.script
query script * format=detailed
Name: QCOLS
Line Number: DESCRIPTION
Command: Display columns for a specified SQL
table
Last Update by (administrator): SERVER_CONSOLE
Last Update Date/Time: 12/02/1997 16:05:29
Name: QCOLS
Line Number: 1
Command: select colname from columns where
tabname='$1'
Last Update by (administrator): SERVER_CONSOLE
Last Update Date/Time: 12/02/1997 16:05:29
Command | Description |
---|---|
COPY SCRIPT | Creates a copy of a script. |
DEFINE SCRIPT | Defines a script to the Tivoli Storage Manager server. |
DELETE SCRIPT | Deletes the script or individual lines from the script. |
RENAME SCRIPT | Renames a script to a new name. |
RUN | Runs a script. |
UPDATE SCRIPT | Changes or adds lines to a script. |