[Digital logo]
[HR]

OpenVMS User's Manual


Previous | Contents

Note the following:

3.4.6 Example

The following example shows how to enter a multiple line command:

$ COPY/LOG FORMAT.TXT,FIGURE.TXT,ARTWORK.TXT -
_$ SAVE.TXT

3.4.7 Entering Multiple Commands

You can use the DCL command PIPE to create complex command processing statements from a single DCL command. For example, you can execute one or more of the following operations from the same DCL command line:

For more detailed information, see Section 16.29 and the description of the PIPE command in the OpenVMS DCL Dictionary: N--Z.

3.5 Rules for Entering DCL Commands

The following sections describe specific rules and requirements you must observe when entering a DCL command.

3.5.1 Case Sensitivity

Use any combination of uppercase and lowercase letters. The DCL interpreter translates lowercase letters to uppercase. Uppercase and lowercase characters in parameter and qualifier values are equivalent unless enclosed in quotation marks (" ").

3.5.2 Required Spaces

3.5.3 Required Punctuation

3.5.4 Null Characters

You cannot specify null characters (<NUL>) on a DCL command line, even if you enclose the null character in quotation marks.

3.5.5 Maximum Elements

Include no more than 127 elements (parameters, qualifiers, and qualifier values) in each command line.

Each element in a command must not exceed 255 characters. The entire command must not exceed 1024 characters after all symbols and lexical functions are converted to their values. You use symbols, described in Chapter 14, to pass information to the system in an abbreviated manner. A lexical function, described in Chapter 17, obtains information from the system, including information about system processes, batch and print queues, and user processes, and then substitutes the result of the operation for itself.

3.5.6 Abbreviating Commands

You can abbreviate a command as long as the abbreviated name remains unique among the defined commands on a system. DCL looks only at the first four characters for uniqueness.

For greater clarity and to ensure that your command procedures are upwardly compatible, do not abbreviate commands in command procedures.

3.5.7 Example

The following commands are equal:

$ PRIN/COPI=2 FORMAL_ART.TXT
$ PRINT/COPIES=2 FORMAL_ART.TXT

3.5.8 Commands in Command Procedures

Additional rules govern the format of commands when they are used in command procedures. See Chapter 15 and Chapter 16 for more information about using commands in command procedures.

3.6 Entering Parameters

File specifications are the most common type of parameter. DCL commands can accept input file specifications (files that are acted upon by a command) and output file specifications (files that are created by a command).

3.6.1 Rules for Specifying Parameters

The following rules apply when specifying parameters in a command line:

3.6.2 Examples

  1. The following example shows how to copy the input file LISTS.TXT to the output file FORMAT.TXT:
    $ COPY LISTS.TXT FORMAT.TXT
    
  2. The following example line shows how you can enter a list of file specifications as the parameter:
    DELETE file-spec[,...] 
    
  3. The following example shows how to specify a list of parameters. Here, three files are copied to a fourth file. The three file specifications, PLUTO.TXT, SATURN.TXT, and EARTH.TXT, constitute the first parameter. PLANETS.TXT is the second parameter. Note that there are no spaces between the PLUTO.TXT, SATURN.TXT, and EARTH.TXT file specifications.
    $ COPY PLUTO.TXT,SATURN.TXT,EARTH.TXT PLANETS.TXT
    

3.7 Entering Qualifiers

There are three types of qualifiers:

The following sections provide information about using and specifying qualifiers.

3.7.1 Abbreviating Qualifiers

You can abbreviate any qualifier name as long as the abbreviated name remains unique among all qualifier names for the same command. However, to ensure that your command procedures are upwardly compatible, do not abbreviate commands and qualifiers in command procedures.

3.7.2 Default Qualifiers

Commands have default qualifiers; you do not have to specify a qualifier unless it is different from the command default. The following sections describe types of qualifiers and qualifier defaults. The OpenVMS DCL Dictionary contains default information for specific commands.

3.7.3 Command Qualifiers

A command qualifier modifies a command and can appear anywhere in the command line. However, it is a good practice to place the qualifier after the command name. If you are specifying multiple qualifiers, you should place a command qualifier with other command qualifiers that follow the command name.

3.7.4 Example

In the following example, /QUEUE is a command qualifier. The files SATURN.TXT and EARTH.TXT are queued to the print queue LN03_PRINT:

$ PRINT/QUEUE=LN03_PRINT SATURN.TXT,EARTH.TXT

3.7.5 Positional Qualifiers

A positional qualifier can modify commands or parameters and has different meanings depending on where you place it in the command string. If you place a positional qualifier after the command but before the first parameter, it affects the entire command string. If you place a positional qualifier after a parameter, it affects only that parameter.

3.7.6 Example

In the following example, the first PRINT command requests two copies of the files SPRING.SUM and FALL.SUM. The second PRINT command requests two copies of the file SPRING.SUM but only one copy of FALL.SUM.

$ PRINT/COPIES=2 SPRING.SUM,FALL.SUM
$ PRINT SPRING.SUM/COPIES=2,FALL.SUM

3.7.7 Parameter Qualifiers

A parameter qualifier can be used only with certain types of parameters, such as input files and output files. For example, the BACKUP command accepts several parameter qualifiers that apply only to input and output file specifications.

3.7.8 Example

In the following example, the /CREATED and /BEFORE qualifiers, which can be specified only with input files, select specific input files for the backup operation. The asterisk (*) is a wildcard character that replaces the file name. BACKUP selects all files with the .TXT file type that were created before December 11, 1996.

$ BACKUP *.TXT/CREATED/BEFORE=11-DEC-1996 NEWFILE.TXT

3.7.9 Conflicting Qualifiers

If you use two or more contradictory qualifiers on a command line, the right-most qualifier overrides the others.

Some commands contain conflicting qualifiers that cannot be specified in the same command line. If you use incompatible qualifiers, the command interpreter displays an error message.

3.7.10 Example

Following is an example of conflicting qualifiers. Note that the PRINT command accepts only the /COPIES=2 and the /NOBURST qualifiers because they are the right-most qualifiers in the command line:

$ PRINT MYFILE/COPIES=3/BURST/COPIES=2/NOBURST EARTH.TXT

3.7.11 Values Accepted by Qualifiers

Qualifiers can accept keywords, file specifications, character strings, and numeric values. When you enter a value for a qualifier, separate the qualifier and the value with either an equal sign (=) or a colon (:).

Some qualifier keywords require additional information. In these cases, separate the keyword from its value with a colon or an equal sign.

To specify multiple keywords that require values, enclose the list in parentheses and separate the keyword and value with either an equal sign (=) or a colon (:).

3.7.12 Examples

3.8 Entering Dates and Times as Values

Certain commands and qualifiers (such as the PRINT/AFTER command) accept date and time values. You can specify these values in one of the following formats:

3.8.1 Absolute Time Format

Absolute time is a specific date or time of day. The format for an absolute time is as follows:

[dd-mmm-yyyy][:hh:mm:ss.cc] 

The fields are as follows:
dd Day of the month: an integer in the range 1 to 31
mmm Month: JAN, FEB, MAR, APR, MAY, JUN, JUL, AUG, SEP, OCT, NOV, or DEC
yyyy Year: an integer
hh Hour: an integer in the range 0 to 23
mm Minute: an integer in the range 0 to 59
ss Second: an integer in the range 0 to 59
cc Hundredths of a second: an integer in the range 0 to 99

3.8.2 Rules for Specifying Absolute Time Format

The following rules apply when specifying absolute time:

3.8.3 Absolute Time Keywords

You can also specify an absolute time as one of the following keywords:
TODAY The current day, month, and year at 00:00:00.0 o'clock
TOMORROW 00:00:00.00 o'clock tomorrow
YESTERDAY 00:00:00.00 o'clock yesterday

3.8.4 Examples: Absolute Time

The following table shows examples of absolute time specifications:
Time Specification Result
11-DEC-1996:13 1 P.M. on December 11, 1996
11-DEC Midnight at the beginning of December 11 this year
15:30 3:30 P.M. today
19-- Midnight on the 19th day of the current year and month
19--:30 12:30 A.M. on the 19th of this month

3.8.5 Delta Time Format

Delta time is an offset (a time interval) from the current date and time to a time in the future. The general format of a delta time is as follows:

"+[dddd-][hh:mm:ss.cc]" 

The fields are as follows:
dddd Number of days; an integer in the range 0 to 9999
hh Number of hours; an integer in the range 0 to 23
mm Number of minutes; an integer in the range 0 to 59
ss Number of seconds; an integer in the range 0 to 59
cc Number of hundredths of seconds; an integer in the range 0 to 99

If a qualifier is described as a value that can be expressed as an absolute time, a delta time, or a combination of the two, you must specify a delta time as if it were part of a combination time. For example, to specify a delta time value of five minutes from the current time, use "+:5" (not "0-0:5").

3.8.6 Rules for Specifying Delta Time Format

The following rules apply when specifying delta time:

3.8.7 Examples

The following table shows some examples of delta time specifications:
Time Specification Result
"+3-" 3 days from now (72 hours)
"+3" 3 hours from now
"+:30" 30 minutes from now
"+3-:30" 3 days and 30 minutes from now
"+15:30" 15 hours and 30 minutes from now

3.8.8 Combination Time Format

To combine absolute and delta times, specify an absolute time plus or minus a delta time. Use one of the following formats:

    "[absolute time][+delta time]" 
 
     [absolute time][-delta time] 

The variable fields and default fields for absolute and delta time values are the same as those described in the preceding sections.

3.8.9 Rules for Specifying Combination Time

The following rules apply when specifying combination time:

3.8.10 Examples

The following table shows some examples of combination time specifications:
Time Specification Result
"+5" 5 hours from now.
"-1" Current time minus 1 hour. The minus sign (-) indicates a negative offset. (The 1 is interpreted as an hour, not a day, because it is not followed by a hyphen.)
"+:5" 5 minutes from now.
"-:5" Current time minus 5 minutes.
"-1-00" Current time minus 1 day. The minus sign (-) indicates a negative offset. The hyphen (-) separates the day from the time field.
"31-DEC:+:5" 12:05 A.M. on December 31 of the current year. The absolute time specification (before the colon) defaults to midnight on December 31 of the current year. The plus sign (+) indicates a positive offset.
31-DEC:-00:10 11:50 P.M. on December 30 of the current year. The absolute time specification (before the colon) defaults to midnight on December 31 of the current year. The minus sign (-) after DEC: indicates a negative offset.

3.9 Recalling Commands

At the DCL prompt, you can recall previously typed command lines to avoid retyping long command lines. Once a command is displayed, you can reexecute or edit it.

On OpenVMS VAX systems, the recall buffer holds up to 20 previously entered commands.

On OpenVMS Alpha systems, the recall buffer holds up to 254 previously entered commands.

You can display your previously entered commands by using one of the following methods:

3.9.1 Using Ctrl/B

Pressing Ctrl/B once recalls the previous command line. Pressing Ctrl/B again recalls the line before the previous line and so on to the last saved command line.

3.9.2 Using Arrow Keys

Pressing the up arrow and down arrow keys recalls the previous and successive command, respectively. Press the arrow keys repeatedly to move through the commands.

3.9.3 Using the RECALL Command

To examine previously typed command lines, type RECALL/ALL. After reviewing the available commands, you can recall a particular command line by typing RECALL and the number of the desired command.

You can also follow RECALL with the first characters of the command line you want to display. RECALL scans the previous command lines (beginning with the most recent one) and returns the first command line that begins with the characters you typed.

3.9.4 Examples

  1. This is a sample display generated by typing RECALL/ALL:
    $ RECALL/ALL
    
     1 SET DEFAULT DISK2:[MARSHALL] 
     2 EDIT ACCOUNTS.COM 
     3 PURGE ACCOUNTS.COM 
     4 DIRECTORY/FULL ACCOUNTS.COM 
     5 COPY ACCOUNTS.COM [.ACCOUNTS]* 
     6 SET DEFAULT [.ACCOUNTS] 
    
  2. The following example shows how to recall the fourth command line:
    $ RECALL 4
    

    After you press Return, the system displays the fourth command in the list at the DCL prompt. (The RECALL command itself is not placed in the buffer.)
  3. The following example shows how to recall a previously entered command, EDIT ACCOUNTS.COM:
    $ RECALL E
    

    After you press Return, the system displays the following command line:
    $ EDIT ACCOUNTS.COM 
    

3.9.5 OpenVMS Screen Management Software

If you are running a utility or an application program that uses OpenVMS screen management software, you can use Ctrl/B and the up arrow and down arrow keys to perform command recall; however, line editing must be enabled. Some utilities that have this feature are Mail, OpenVMS Debugger, Show Cluster, the System Dump Analyzer (SDA), and the EVE editor.

3.9.6 Erasing the Recall Buffer

To erase the contents of the recall buffer, enter the RECALL command with the ERASE qualifier. For example:

$ RECALL/ERASE

For security reasons, it is good practice to erase the contents of the recall buffer after you have entered commands that include passwords.

3.10 Editing the DCL Command Line

At the DCL command level, you can use many individual keys and key sequences to change what you type. Although different types of terminals have different operating characteristics, most have standard function keys and keys that can be used with line editors.

3.10.1 SHOW TERMINAL Command

To see whether line editing is enabled on your terminal, enter the SHOW TERMINAL command. The current status of line editing is displayed in the first column under Terminal Characteristics.

3.10.2 Example

In the following example, line editing is not enabled:

$ SHOW TERMINAL 
 
Terminal: _VTA130:    Device_Type: VT200_Series  Owner: ROHBA 
LAT Server/Port: L121/Port_3 
Physical terminal: _LTA130: 
   Input:   9600      LFfill:  0      Width:  80      Parity: None 
   Output:  9600      CRfill:         Page:   24 
Terminal Characteristics: 
 Interactive        Echo               Type_ahead       No Escape 
 No Hostsync        TTsync             Lowercase        Tab 
 Wrap               Scope              No Remote        No Eightbit 
 Broadcast          No Readsync        No Form          Fulldup 
 No Modem           No Local_echo      No Autobaud      Hangup 
 No Brdcstmbx       No DMA             No Altypeahd     Set_speed 
 No Line Editing    Insert editing     No Fallback      No Dialup 
 No Secure server   Disconnect         No Pasthru       No Syspassword 
 No SIXEL Graphics  No Soft Characters No Printer Port  Numeric Keypad 
 ANSI_CRT           No Regis           No Block_mode    Advanced_video 
 No Edit_mode       DEC_CRT            No DEC_CRT2 

3.10.3 SET TERMINAL Command

You can use the SET TERMINAL command to alter the way in which your terminal edits a DCL command line. By default, changes made with the SET TERMINAL command apply only to the current session. To set the terminal each time you log in, you can include SET TERMINAL commands in your LOGIN.COM file.

3.10.4 Enabling Line Editing

To enable line editing, enter the SET TERMINAL/LINE_EDIT command:

$  SET TERMINAL/LINE_EDIT

3.10.5 Changing Edit Modes

You can edit a command line in either insert or overstrike mode. In insert mode, the character you type is inserted to the left of the cursor. In overstrike mode, the character you type overwrites the character indicated by the cursor.

To change editing modes for a single command line, press Ctrl/A (Ctrl/A acts as a toggle). To change edit modes for your session, enter either the SET TERMINAL/INSERT or SET TERMINAL/OVERSTRIKE command.

3.10.6 Making Command Lines Wrap

If you use the SET TERMINAL/WRAP command, when you enter more characters than will fit on one line of the terminal screen, the text wraps to the next line.

You can edit only the line where your cursor appears. When text wraps, you cannot use the up arrow key to move the cursor up to edit the previous line. To move the cursor up to the previous line, use the Delete key and delete all the characters in the current line.

3.10.7 Deleting Portions of the Command Line

The Delete key on your keyboard is marked with either the word Rubout, the word Delete, or an X in a left-pointing arrow, depending on the type of terminal you are using. The Delete key back spaces over the most recently entered character and deletes it. On a hardcopy terminal, the deleted letters are displayed between backslash characters so you can see what is being deleted. On a video display terminal, pressing the Delete key erases the character from the screen and moves the cursor backwards.


Previous | Next | Contents | [Home] | [Comments] | [Ordering info] | [Help]

[HR]

  6489P004.HTM
  OSSG Documentation
  22-NOV-1996 13:16:36.99

Copyright © Digital Equipment Corporation 1996. All Rights Reserved.

Legal