 |
HP OpenVMS DCL Dictionary
HP OpenVMS DCL Dictionary
If you enter the /OUTPUT qualifier with a partial file specification
(for example, /OUTPUT=[VAKHRAMEEV]), TYPE is the default file name and
.LIS the default file type. The file specification cannot include the
asterisk (*) and the percent sign (%) wildcard characters.
If you enter the /NOOUTPUT qualifier, output is suppressed.
The /OUTPUT qualifier is incompatible with the /PAGE qualifier.
/PAGE[=keyword]
/NOPAGE (default)
Controls the display of information on the screen.
You can use the following keywords with the /PAGE qualifier:
CLEAR_SCREEN
|
Clears the screen before each page is displayed.
|
SCROLL
|
Displays information one line at a time.
|
SAVE[=
n]
|
Enables screen navigation of information, where
n is the number of pages to store.
|
The /PAGE=SAVE qualifier allows you to navigate through screens of
information. The /PAGE=SAVE qualifier stores up to 5 screens of up to
255 columns of information. When you use the /PAGE=SAVE qualifier, you
can use the following keys to navigate through the information:
Key Sequence |
Description |
Up arrow key, Ctrl/B
|
Scroll up one line.
|
Down arrow key
|
Scroll down one line.
|
Left arrow key
|
Scroll left one column.
|
Right arrow key
|
Scroll right one column.
|
Find (E1)
|
Specify a string to find when the information is displayed.
|
Insert Here (E2)
|
Scroll right one half screen.
|
Remove (E3)
|
Scroll left one half screen.
|
Select (E4)
|
Toggle 80/132 column mode.
|
Prev Screen (E5)
|
Get the previous page of information.
|
Next Screen (E6), Return, Enter, Space
|
Get the next page of information.
|
F10, Ctrl/Z
|
Exit. (Some utilities define these differently.)
|
Help (F15)
|
Display utility help text.
|
Do (F16)
|
Toggle the display to oldest/newest page.
|
Ctrl/W
|
Refresh the display.
|
N
|
Display the next file (when more than one file is specified with the
TYPE command)
|
Q
|
Quit displaying output from the TYPE command.
|
The /PAGE qualifier is not compatible with the /OUTPUT qualifier.
/SEARCH="string"
Use with the /PAGE=SAVE qualifier to specify a string that you want to
find in the information being displayed. Quotation marks are required
for the /SEARCH qualifier, if you include spaces in the text string.
You can also dynamically change the search string by pressing the Find
key (E1) while the information is being displayed. Quotation marks are
not required for a dynamic search.
/SINCE[=time]
Selects only those files dated on or after the specified time. You can
specify time as absolute time, as a combination of absolute and delta
times, or as one of the following keywords: BOOT, LOGIN, TODAY
(default), TOMORROW, or YESTERDAY. Specify one of the following
qualifiers with the /SINCE qualifier to indicate the time attribute to
be used as the basis for selection: /BACKUP, /CREATED (default),
/EXPIRED, or /MODIFIED.
For complete information on specifying time values, refer to the
OpenVMS User's Manual or the online help topic DCL_Tips (subtopic Date_Time).
/STYLE=keyword
Specifies the file name format for display purposes while typing files.
The valid keywords for this qualifier are CONDENSED and EXPANDED.
Descriptions are as follows:
Keyword |
Explanation |
CONDENSED (default)
|
Displays the file name representation of what is generated to fit into
a 255-length character string. This file name may contain a DID or FID
abbreviation in the file specification.
|
EXPANDED
|
Displays the file name representation of what is stored on disk. This
file name does not contain any DID or FID abbreviations.
|
The keywords CONDENSED and EXPANDED are mutually exclusive. This
qualifier specifies which file name format is displayed in the output
message, along with the confirmation if requested.
File errors are displayed with the CONDENSED file specification unless
the EXPANDED keyword is specified.
Refer to the OpenVMS User's Manual for more information.
/TAIL[=n]
Displays the last several lines of a log file. The value, n, defaults
to p-2 where p is the current terminal page length. You can use
TYPE/TAIL only if all of the following criteria are true:
- File organization is sequential.
- The longest record is less than 512 bytes.
- The record format is either VAR, VFC, STM, STRCM or STMLF (for more
information, refer to the description of FAB$B_RFM in the
OpenVMS Record Management Services Reference Manual).
- The file being typed is on a device that supports random access.
The TYPE/TAIL command does not work on magnetic tape drives.
Even with this criteria, some file conditions cannot be anticipated and
may not allow display of the last several lines of a log file,
resulting in the following error message:
%TYPE-W-READERR, error reading DEVICE:[DIRECTORY]FILE.EXT;1
-SYSTEM-E-UNSUPPORTED, unsupported operation or function
|
/WRAP
/NOWRAP (default)
Use with the /PAGE=SAVE qualifier to limit the number of columns to the
width of the screen and to wrap lines that extend beyond the width of
the screen to the next line.
The /NOWRAP qualifier extends lines beyond the width of the screen and
can be seen when you use the scrolling (left and right) features
provided by the /PAGE=SAVE qualifier.
Examples
In this example, the TYPE command requests that the file COMMON.DAT be
displayed at the terminal.
#2 |
$ TYPE *.DAT
This is the first line in the file AA.DAT.
.
.
.
[Ctrl/O]
This is the first line in the file BB.DAT.
.
.
.
[Ctrl/Y]
Interrupt
$ STOP
|
In this example, the TYPE command contains an asterisk (*) wildcard
character in place of the file name. All files with file types of .DAT
are scheduled for display. When Ctrl/O is pressed, output of the
current file stops and the TYPE command begins displaying the next
file. The Ctrl/Y function interrupts the command; the STOP command
terminates the TYPE command.
#3 |
$ TYPE LETTER*.MEM
December 14, 2002
.
.
.
[Ctrl/Y]
Interrupt
$ SHOW TIME
14-DEC-2002 15:48:07
$ CONTINUE
Sincerely yours,
.
.
.
|
In this example, the TYPE command displays all files whose names begin
with the word LETTER and have the file type .MEM. While the files are
being displayed, the user presses Ctrl/Y to interrupt the TYPE
operation and to display the time. After entering the SHOW TIME
command, the user enters the CONTINUE command to resume the TYPE
operation.
#4 |
$ TYPE/OUTPUT=SAVETEXT.TXT *.TXT
|
In this example, the TYPE command writes all TXT files in your default
directory to a file called SAVETEXT.TXT (also in your default
directory).
#5 |
$ TYPE MEXICO::NOTICE.TEXT/OUTPUT=TEMP.TEXT
|
In this example, the TYPE command requests that the file NOTICE.TEXT at
remote node MEXICO be written to the output file TEMP.TEXT on the local
node, rather than to SYS$OUTPUT.
#6 |
$ TYPE SECSYS"FILES OFFICEFIL"::"TASK=SHOWUSERS"
VAX/VMS Interactive Users
14-DEC-2002 17:20:13.30
Total number of interactive users = 5
Username Process Name PID Terminal
MIRANDA Sec1 00536278 TXA1:
JESSICA Sec2 00892674 VTA2:
EMILY Sec3 00847326 TXA3:
ANDREW Sec4 02643859 RTA1:
BRIAN System Mangr 00007362 VTA1:
|
In this example, the TYPE command executes the command procedure
SHOWUSERS.COM found in the SYS$LOGIN directory of user FILES on remote
node SECSSYS. The output of the TYPE command then is displayed at the
local node.
VIEW
Invokes the CDA Viewer, which has a character-cell interface for
viewing text files and an DECwindows Motif for OpenVMS interface for
viewing compound documents and files containing graphics, images, and
tabular data.
For more information about the VIEW command, refer to online help.
Note
The DEC CDA Base Services for DECwindows Motif for OpenVMS must be
installed to use new versions of the CDA Viewer and DEC CDA Base
Services converters.
|
Format
VIEW [input-file]
WAIT
Places a process into a wait state for the specified amount of time.
The WAIT command is used in a command procedure to delay processing of
either the procedure itself or a set of commands in the procedure.
Format
WAIT delta-time
Parameter
delta-time
Specifies a delta time interval in the following format. (A delta time
is an offset from the current time to a time in the future.)
hour:minute:second.hundredth
|
The fields on the format line indicate the following:
hour
|
Specifies an integer in the range 0 to 23.
|
minute
|
Specifies an integer in the range 0 to 59.
|
second
|
Specifies an integer in the range 0 to 59.
|
hundredth
|
Specifies an integer in the range 0 to 99.
|
The colons (:) and period (.) are required delimiters; also, the delta
time must begin with the number of hours and not a colon. Note that the
days field, usually included in the delta time format, must be omitted
here.
For more information on specifying delta time values, refer to the
OpenVMS User's Manual or the online help topic DCL_Tips (subtopic Date_Time).
Note that if you enter the WAIT command interactively, you are not
prompted for a time value; however, in order for the command to have
any effect, you must supply a time value.
Description
If you enter the WAIT command interactively, your current process is
placed in a wait state and you cannot enter any more commands until the
waiting period is over. (You can, however, receive unsolicited messages
from other processes.) Press Ctrl/C or Ctrl/Y to restore normal
terminal interaction.
Example
|
$ LOOP:
$ RUN KUDOS
$ WAIT 00:10
$ GOTO LOOP
|
In this example, the command procedure executes the program image
KUDOS. After the RUN command executes the program, the WAIT command
delays execution of the GOTO command for 10 minutes. Note that 00 is
specified for the number of hours, because the time specification
cannot begin with a colon. After 10 minutes, the GOTO command executes,
and the procedure transfers control to the label LOOP and executes the
program KUDOS again. The procedure loops until it is interrupted or
terminated.
If the procedure is executed interactively, terminate it by pressing
Ctrl/C or Ctrl/Y and by entering the STOP command or another DCL
command that runs a new image in the process. If the procedure is
executed in a batch job, enter the DELETE/ENTRY command to terminate it.
WRITE
Writes the specified data as one record to an open file specified by a
logical name.
All qualifiers must precede all data item expressions.
Format
WRITE logical-name expression[,...]
Parameters
logical-name
Specifies the logical name assigned to the output file. Use the logical
name assigned by the OPEN command. In interactive mode, specify the
process-permanent files identified by the logical names SYS$INPUT,
SYS$OUTPUT, SYS$ERROR, and SYS$COMMAND. (The OPEN command assigns a
logical name to a file and places the name in the process logical name
table.)
expression[,...]
Specifies data to be written as a single record to the output file. You
can specify data items using character string expressions, which may be
symbol names, character strings in quotation marks (" "),
literal numeric values, or a lexical function. For more information on
string expressions, refer to the OpenVMS User's Manual.
You can specify a list of expressions separated by commas (,); the
command interpreter concatenates the items into one record and writes
the record to the output file.
The maximum size of any record that can be written is less than 1024
bytes, and the value of any symbol that is specified as part of a
record cannot exceed 255 characters; however, if you specify the
/SYMBOL qualifier, the maximum record size is 2048 bytes and the value
of a symbol can exceed 255 characters.
Description
The WRITE command can write records to sequential, relative, or indexed
files that have been opened for writing. When the WRITE command writes
a record, it always positions the record pointer after the record just
written.
To write to a file, the file must be opened by using either the /WRITE
or the /APPEND qualifier with the OPEN command; however, the
process-permanent files identified by the logical names SYS$INPUT,
SYS$OUTPUT, SYS$ERROR, and SYS$COMMAND do not have to be opened
explicitly to be written to.
If you do not specify the /SYMBOL qualifier, DCL places the command and
the complete string expression (expanded if it was specified as one or
more symbols) in a 1024-byte buffer. If you specify the /SYMBOL
qualifier, DCL interprets the symbol or symbols and places the expanded
string in a separate 2048-byte buffer, and then performs the write
operation. For this reason, use the /SYMBOL qualifier where the record
contains approximately 1000 bytes or more.
Qualifiers
/ERROR=label
Transfers control on an I/O error to the location specified by
label (in a command procedure). If no error routine is
specified and an error occurs during the writing of the file, the
current ON condition action is taken. The /ERROR qualifier overrides
any ON condition action specified. If an error occurs and control
passes successfully to the target label, the reserved global symbol
$STATUS retains the error code.
/SYMBOL
Causes the expression to be interpreted and its expanded value placed
in a 2048-byte (instead of a 1024-byte) buffer before the write
operation is performed. If you specify multiple expressions, their
values are concatenated and placed in the 2048-byte buffer. Use the
/SYMBOL qualifier to write a very large record.
Each expression specified must be a symbol. You cannot specify
character string expressions (that is, strings in quotation marks) with
the /SYMBOL qualifier.
If you do not use the /SYMBOL qualifier, the entire command, including
the expression or expressions, is placed in a 1024-byte buffer.
/UPDATE
Replaces the last record read with the record specified with the
expression parameter. You must be able to read and write to a file to
use the /UPDATE qualifier. Use the WRITE/UPDATE command only after a
READ command. The WRITE/UPDATE command modifies the last record you
have read.
With sequential files, you must replace a record with another record of
the same size when you use the WRITE/UPDATE command.
Examples
#1 |
$ WRITE SYS$OUTPUT "Beginning second phase of tests"
|
The WRITE command writes a single line of text to the current output
device.
#2 |
$ OPEN/APPEND OUTPUT_FILE TRNTO::DKA1:[PGM]PLAN.DAT
$ WRITE OUTPUT_FILE "BEGINNING PHASE 3"
|
In this example, the OPEN/APPEND command opens the file PLAN.DAT at the
remote node TRNTO and positions the pointer at the end of the file. The
WRITE command writes a record to the end of the file PLAN.DAT.
#3 |
$ OPEN/WRITE OUTPUT_FILE TESTFILE.DAT
$ INQUIRE ID "Assign Test-id Number"
$ WRITE/ERROR=WRITE_ERROR OUTPUT_FILE "Test-id is ",ID
$ WRITE/ERROR=WRITE_ERROR OUTPUT_FILE ""
$ !
$ WRITE_LOOP:
.
.
.
$ GOTO WRITE_LOOP
$ END_LOOP:
$ !
$ CLOSE OUTPUT_FILE
$ PRINT TESTFILE.DAT
$ EXIT
$ !
$ WRITE_ERROR:
$ WRITE SYS$OUTPUT "There was a WRITE error."
$ CLOSE OUTPUT_FILE
$ EXIT
|
In this example, the OPEN command opens the file TESTFILE.DAT; the
INQUIRE command requests an identification number to be assigned to a
particular run of the procedure. The number entered is equated to the
symbol ID. The WRITE commands write a text line concatenated with the
symbol name ID and a blank line.
The lines between the label WRITE_LOOP and END_LOOP process information
and write additional data to the file. When the processing is finished,
control is transferred to the label END_LOOP. The CLOSE and PRINT
commands at this label close the output file and queue a copy of the
file to the system printer.
The label WRITE_ERROR is used as the target of the /ERROR qualifier to
the WRITE command; if an error occurs when a record is being written,
control is transferred to the label WRITE_ERROR.
#4 |
$ OPEN/APPEND MYFILE [LAMPERT]TESTING.DAT
$ WRITE/SYMBOL MYFILE A,B,C
|
This example assumes that the symbols A, B, and C have already been
defined. The OPEN/APPEND command opens the file [LAMPERT]TESTING.DAT
and positions the pointer at the end of the file. The WRITE/SYMBOL
command concatenates the values of the symbols A, B, and C and writes
this data to a new record at the end of the file.
XAUTH (Alpha Only)
Invokes the X Authority utility (xauth) that you can use to manage the
contents of one or more X authority files. The X authority file
contains information used to authorize client connections to the X
display server.
This utility is typically used to extract authorization records from
one system and combine them with the records on another system, such as
when granting access to additional users or enabling remote logins. The
actual record entries vary depending on the authorization scheme
currently in use.
In contrast to other X Window System utilities that are available with
DECwindows Motif, xauth is included as a part of OpenVMS Alpha
operating system. The xauth commands are case-insensitive and available
directly from the DCL command line, xauth command line, or from a batch
file.
For a complete description of xauth, refer to the DECwindows Motif
documentation (available on the Documentation CD-ROM) or the xauth
online help.
Format
XAUTH [-f authfile] [-options...] [command]
|