[OpenVMS documentation]
[Site home] [Send comments] [Help with this site] [How to order documentation] [OpenVMS site] [Compaq site]
Updated: 11 December 1998

OpenVMS User's Manual


Previous Contents Index

4.8.3 Print Forms

A print form serves the following functions:

If your printing needs are limited, you do not need to use special forms because Compaq supplies a systemwide default form (named DEFAULT) for all queues. System managers can also create print forms. If you need to format output or if certain print jobs require special paper, contact your system manager.

4.8.4 Stopping a Print Job

To stop a print job and delete it from the print queue, enter the entry number parameter to the DELETE/ENTRY command.

In the following example, entry 202 is deleted:


$ DELETE/ENTRY=202

4.8.5 Printing Files on Other Nodes

To print a file on another system, copy that file to the remote node and specify the /REMOTE qualifier to the PRINT command.

In the following example, the file COMPANY_HOLIDAYS.TXT is copied from the local node to the remote node CHAOS and the file is queued for printing to the default system print queue (SYS$PRINT) on node CHAOS:


$ COPY COMPANY_HOLIDAYS.TXT CHAOS"JONES PANDEMONIUM"::DISK2:[JONES]* 
$ PRINT/REMOTE CHAOS::DISK2:[JONES]COMPANY_HOLIDAYS.TXT

An access control string indicates that the user JONES is authorized to copy files to the directory [JONES] on node CHAOS. The asterisk (*) wildcard at the end of the file specification instructs the system to duplicate the file name COMPANY_HOLIDAYS.TXT when that file is copied to the remote node.

Note

Not all qualifiers to the PRINT command are compatible with the /REMOTE qualifier. For example, you cannot queue a job to a specific print queue; all jobs are queued to the default system print queue (SYS$PRINT). See the description of the /REMOTE qualifier to the DCL command PRINT in the OpenVMS DCL Dictionary for a list of PRINT command qualifiers compatible with /REMOTE.

4.8.6 PRINT Command Qualifiers

Print jobs can be controlled in various ways by using qualifiers to the PRINT command. For example, you can specify the number of copies printed or you can request that the system notify you when your print job is complete.

In addition to the qualifiers described in this manual, if you are running DECprint Supervisor software on your system, you can use the /PARAMETER qualifier to print landscape, two-sided, or many other ways. Contact your system manager for a list of print options that are available on your system.

The following table lists a summary of PRINT command qualifiers. For complete information on the PRINT command, refer to the OpenVMS DCL Dictionary or online help.
Print Operations Print Job Commands and Qualifiers
Number of copies:
By job
By file
Specified file only

PRINT/JOB_COUNT=n 1
PRINT/COPIES=n 1
file-spec/COPIES=n 1
Number of pages PRINT/PAGES= 1
Print features:
Flag pages
Type of forms (paper)
Special features
Double-spacing
Page heading

PRINT/FLAG= 1
PRINT/FORM= 1
PRINT/CHARACTERISTICS= 1
PRINT/SPACE 1
PRINT/HEADER 1
Notification of job execution PRINT/NOTIFY
Delay execution of a job:
For a specified time
Indefinitely

PRINT/AFTER
PRINT/HOLD
Release a delayed job SET QUEUE/ENTRY/RELEASE
Display your print jobs SHOW ENTRY
Stop a print job:
Delete job
Stop current job
and begin printing
the next job
in the queue
Stop current job
and requeue it
for printing

DELETE/ENTRY=job-number
STOP/ABORT



STOP/REQUEUE
Keep a job in a queue
after it has completed
PRINT/RETAIN


1Parallel qualifiers for the SET QUEUE/ENTRY command allow you to specify these operations for print jobs that are already queued but not yet printing.


Chapter 5
Directories: Organizing and Managing Files

Directories are files that store the names of files. This chapter describes how to use directories to organize and manage files. This chapter includes information about:

Note

Throughout this chapter, examples that specify a node name do not always include an access control string. This is because proxy accounts enable users to perform operations on the remote systems in these examples.

If you are working in an environment with Extended File Specifications, directory structures and syntax may differ greatly from the traditional structures described here. For information about working with directories in such an environment, refer to the OpenVMS Guide to Extended File Specifications.

For more information, refer to the following:

5.1 Directory Structures

Figure 5-1 shows a sample directory hierarchy. At the top of the structure is the master file directory (MFD). Its directory name is [000000]. The MFD shown contains entries for user file directories including MARTINO.DIR, PUBLIC.DIR, and JONES.DIR. The top-level directory [JONES] is a user file directory named JONES.DIR;1 in [000000].

The sample directory structure in Figure 5-1 is the basis for many of the examples in this chapter.

Figure 5-1 Directory Structure


Note the following about this directory structure:

  1. Assume that you are user JONES. When you log in, the system places you in [JONES], your default directory.
  2. [JONES] contains the following four nondirectory files:
  3. [JONES] also contains the following two directory files:
  4. The directory file LICENSES.DIR;1 points to the [JONES.LICENSES] subdirectory.
  5. TAXES.DIR;1 points to the [JONES.TAXES] subdirectory.
  6. The [JONES.LICENSES] subdirectory contains three nondirectory files and two directory files.
  7. The directory file DOG.DIR;1 points to the [JONES.LICENSES.DOG] subdirectory.
  8. MARRIAGE.DIR points to the [JONES.LICENSES.MARRIAGE] subdirectory.

5.2 Understanding Directories

Use a directory specification to refer to a directory. A directory specification consists of a top-level directory name that can be followed by a maximum of seven subdirectory names. Subdirectory names are always preceded by a period (.).

Note

Directory structures in an environment with Extended File Specifications differ from those in a typical environment without Extended File Specifications. If you are working with Extended File Specifications, refer to the OpenVMS Guide to Extended File Specifications for further information about deep directory structures and syntax.

A directory specification has the following format:

[directory.subdirectory] 

To add one or more levels of subdirectories, add a period and another subdirectory name for each subdirectory (up to seven levels). (Subdirectories are specified by concatenating the subdirectory name to the name of the directory one level above it.)

[directory.subdirectory.subdirectory] 

A directory or subdirectory name can contain up to 39 alphanumeric characters. Any characters valid for file names are also valid for directory names. Enclose the directory name in either square brackets ([ ]) or angle brackets (< >).

5.2.1 Creating Directories

To create a directory, enter the CREATE/DIRECTORY command. If you want to create a subdirectory under your current directory, you do not have to specify the current directory name; you can enter the subdirectory name preceded by a period.

In the following example, the directory [JONES.LICENSES] is created:


$ CREATE/DIRECTORY [JONES.LICENSES]

In the following example, the current default directory is [JONES], and the subdirectory [JONES.LICENSES] is created:


$ CREATE/DIRECTORY [.LICENSES]

5.2.2 Displaying Directories

To display the names of files in a directory, enter DIRECTORY at the DCL prompt. To list the files in a subdirectory, enter the DIRECTORY command and the subdirectory name preceded by a period.

When you include certain command qualifiers along with the DIRECTORY command, you can retrieve information in addition to the names of the files. For more information on DIRECTORY command qualifiers, refer to the OpenVMS DCL Dictionary or online help.

In the following example, the files in the directory [JONES] are listed. The example shows that [JONES] contains two subdirectories, [JONES.LICENSES] and [JONES.TAXES], four nondirectory files, STAFF.DIS, STAFF_VACATIONS.TXT, and two versions of LOGIN.COM:


$ DIRECTORY


Directory DISK1:[JONES] 
 
LICENSES.DIR;1 
LOGIN.COM;3 
LOGIN.COM;4 
STAFF.DIS;3 
STAFF_VACATIONS.TXT;2 
TAXES.DIR;1 
 
Total of 6 files.

In the following example, the default directory remains [JONES] and the contents of the subdirectory [JONES.LICENSES] are displayed:


$ DIRECTORY [.LICENSES]


Directory DISK1:[JONES.LICENSES] 
 
DEPT.DAT;3 
DOG.DIR;1 
MAILING.LIS;6 
MARRIAGE.DIR;1 
TOTAL.DAT;2 
 
Total of 5 files.

5.2.3 Deleting Directories

To delete a directory, use the following procedure:
Step Task
1 Make sure that the directory contains no files. To find out if the directory contains files, enter the DIRECTORY command.

When there are no files in the directory, the system displays the following message:

%DIRECT-W-NOFILES, no files found

2 If the directory contains files, copy them to another directory to save them or delete them if you do not want to save them. If the directory contains subdirectories, examine those subdirectories, copy or delete their files, and delete the subdirectories.
3 Move to the directory one level above the directory you want to delete. Remember that subdirectories exist as files in directories. When you delete a directory, you delete the file that points to that directory.
4 Change the file protection of a directory to allow delete access to the file. Directory files in master file directories require SYSPRV privilege to delete. (See Chapter 4 for more information about file protection.)
5 Delete the directory file using the DELETE command.

The following example shows how to delete the subdirectory [JONES.LICENSES]:


$ SET DEFAULT [JONES.LICENSES]
$ DIRECTORY
%DIRECT-W-NOFILES, no files found
$ SET DEFAULT [JONES]
$ SET SECURITY/PROTECTION=OWNER:D LICENSES.DIR
$ DELETE LICENSES.DIR;1

5.3 Setting Defaults

To change your default directory, use the SET DEFAULT command. The new default remains in effect until you enter another SET DEFAULT command or log out. To set default to a subdirectory, append the subdirectory name to the name of the directory one level above it.

In the following example, default is set to the directory [JONES] and then the file [JONES]STAFF_VACATIONS.TXT is displayed:


$ SET DEFAULT [JONES]
$ TYPE STAFF_VACATIONS.TXT

In the following example, the file BILLING.DAT, which is located in the subdirectory [JONES.TAXES], is displayed:


$ SET DEFAULT [JONES.TAXES]
$ TYPE BILLING.DAT

5.3.1 Setting Default to Nonexistent Directories

Note that the operating system allows you to set default to a nonexistent disk or directory. If you have set default to a nonexistent directory, when you try to manipulate a file, the system displays a message stating that the directory does not exist. If you find yourself in a nonexistent disk or directory and cannot carry out a desired operation, set default to an existing disk or directory.

5.3.2 SHOW DEFAULT Command

To display your current default directory, enter the command SHOW DEFAULT, as shown in the following example:


$ SHOW DEFAULT
  DISK1:[JONES.TAXES]
$ SET DEFAULT [PUBLIC]
$ SHOW DEFAULT
  DISK1:[PUBLIC]

You can use the SET DEFAULT command to change the default device. The default remains in effect until you enter another SET DEFAULT command or log out. You can also specify the device to which you want to set default without including the directory in the command.

The following example shows how to change the default device:


$ SHOW DEFAULT
  DISK1:[JONES]
$ SET DEFAULT DISK2:[GROUP]
$ SHOW DEFAULT
  DISK2:[GROUP]

In the following example, the directory [JONES] is assumed and exists on DISK1 and DISK2:


$ SHOW DEFAULT
  DISK1:[JONES]
$ SET DEFAULT DISK2:
$ SHOW DEFAULT
  DISK2:[JONES]

5.3.3 Using Temporary Defaults

If you enter a list of files and do not give a complete file specification for each file in the list, the system applies temporary defaults for node names, device names, and directory names. To substitute your current default directory for a temporary default, use empty square brackets. If you include a node name in a file that appears in a list, you can override the temporary default by using a double colon.

In the following example, A.LIS and B.LIS are copied from the [STATS] directory to the [RESULTS] directory:


$  COPY [STATS]A.LIS,B.LIS  [RESULTS]

Note that the system uses the preceding file specification in the list, [STATS]A.LIS, to determine that the temporary default directory for file B.LIS is [STATS] as well.

In the following example, a temporary default device and two different directories are used:


$  COPY BASE:[STATS]A.LIS,[TIME]B.LIS,C.LIS  [RESULTS]

All three files (A.LIS, B.LIS, and C.LIS) are copied from the BASE device. The A.LIS file is copied from the [STATS] directory. The other two files are copied from the [TIME] directory.

In the following example, the current default directory is [BETA]. This command copies [ALPHA]TEST.DAT and [BETA]FINAL.DAT to the [RESULTS] directory:


$  COPY [ALPHA]TEST.DAT,[]FINAL.DAT  [RESULTS]

5.4 Protecting Directories from Other Users

You cannot completely protect a file without applying at least the same protection to the directory in which the file resides. For example, if you deny a user all access to a file but allow that user read access to the file's directory, the user cannot access the contents of the file but can see that it exists. Conversely, a user allowed access to a file and denied access to the file's directory (or one of the parent directories) cannot see that the file exists.

Note

To protect private files, directory protection alone is not adequate. You must also protect each file within the directory.

By default, top-level directories receive UIC-based protection (S:RWE,O:RWE,G:RE,W:E) and no ACL. Subdirectories receive UIC-based protection from the parent directory. For more information on protection codes, see Section 19.3.

To specify UIC-based protection explicitly when creating a directory, use the /PROTECTION qualifier with the CREATE/DIRECTORY command. You cannot specify an ACL for the directory until the directory is created. To change the UIC-based protection of an existing directory, apply the SET SECURITY/PROTECTION command to the directory file.

You can limit but not prohibit directory access by specifying execute access but not read access. Execute access on a directory permits you to examine and read files that you know are contained in the directory; that means you can examine a file if you already know what the file specification is, but you cannot display a list of the files in the directory. For additional security information, see OpenVMS Guide to System Security.

5.5 Using Wildcards to Search the Directory Structure

From any point in a directory structure, you can refer to another directory or subdirectory in the structure. Do this by specifically naming the directory or subdirectory you want or by using the ellipsis (...) and hyphen (-) wildcard characters. For additional information about wildcards, see Section 4.2.

If you are working in an environment with Extended File Specifications, refer to the OpenVMS Guide to Extended File Specifications for further information about searching directory structures with wildcards.

5.5.1 Ellipsis Wildcard Character

Use the ellipsis (...) wildcard character to search down into the directory hierarchy. To search the current directory and all the subdirectories below it, use the ellipsis by itself as shown:


$ DIRECTORY [...]

If you begin the directory specification with an ellipsis, the search begins from your current directory. However, if you begin the directory specification with a period, only the subdirectory that is one level lower than the current directory is searched.

To search all top-level directories and their subdirectories from wherever you are in the directory structure, use an asterisk (*) followed by an ellipsis (...).

In the following example, assuming the current directory is [JONES], the latest versions of all files named FEES.DAT in [JONES] and all subdirectories under [JONES] will be displayed:


$ TYPE [JONES...]FEES.DAT

In the following example, assuming the current default directory is [JONES], all subdirectories that end in .SALES are searched, and the latest versions of the file FEDERAL.LIS are displayed:


$ TYPE [...SALES]FEDERAL.LIS

In the following example, the latest versions of all files named DEPT.DAT in [JONES] and all subdirectories under [JONES] are displayed:


$ TYPE [...]DEPT.DAT 

In the following example, assuming the current directory is [JONES], the [.LICENSES] subdirectory will be searched for the file MAILING.LIS, but [JONES.LICENSES.MARRIAGE] will not:


$ TYPE [.LICENSES]MAILING.LIS

In the following example, assuming the current directory is [JONES], the latest versions of all files named DEPT.DAT in the [.LICENSES] subdirectory under [JONES] and all subdirectories under the [.LICENSES] subdirectory are displayed:


$ TYPE [...LICENSES...]DEPT.DAT

In the following example, as many as eight levels of directory names (the top-level directory and seven subdirectories) are searched (if they exist). Note that the command shown requires READALL privilege.


$ DIRECTORY [*...]


Previous Next Contents Index

[Site home] [Send comments] [Help with this site] [How to order documentation] [OpenVMS site] [Compaq site]
[OpenVMS documentation]

Copyright © Compaq Computer Corporation 1998. All rights reserved.

Legal
6489PRO_009.HTML