Where allowed to run: All environments (*ALL) Threadsafe: No |
Parameters Examples Error messages |
The Move Document (MOVDOC) command changes the path the system uses to search for a document. The document is not physically moved to another location of auxiliary storage, and a new object is not created.
Restrictions:
Top |
Keyword | Description | Choices | Notes |
---|---|---|---|
FROMDOC | From document | Character value, *SYSOBJNAM | Required, Positional 1 |
FROMFLR | From folder | Character value, *NONE | Optional, Positional 2 |
TOFLR | To folder | Character value, *NONE | Optional, Positional 3 |
RENAME | Rename | Character value, *SAME | Optional, Positional 4 |
SYSOBJNAM | System object name | Name | Optional |
Top |
Specifies the document to be moved. If a document name is specified on the FROMDOC parameter, then a folder name must be specified on the From folder (FROMFLR) parameter. If *SYSOBJNAM is specified on the FROMDOC parameter, then a system object name must be specified on the System object name (SYSOBJNAM) parameter.
Note: If FROMDOC(name) is specified, then FROMFLR(name) is required. If FROMDOC(*SYSOBJNAM) is specified, then SYSOBJNAM(name) and RENAME(name) are required.
This is a required parameter.
Top |
Specifies the name of the folder from which the document is being moved. A folder name must be entered on this parameter if a document name is entered on the From document (FROMDOC) parameter. FROMFLR(*NONE) cannot be specified if FROMDOC(name) is specified.
Top |
Specifies the name of the folder into which the document is being moved. A folder name must be entered in this parameter if a document name is entered in the Rename (RENAME) parameter.
Top |
Specifies the name by which the moved document is to be known in the TOFLR folder. This parameter allows the user to name a document when moving a folderless document to a folder. It also allows the user to rename the document when moving it from one folder to another.
If the user wants to move a document into a folder, the name of the document in the TOFLR folder must be unique.
If the new name is already assigned to a folder or a document in a folder specified on the TOFLR parameter, the user must either choose a new name for the target document or rename the folder or document that has the same name.
Note: If FROMDOC(*SYSOBJNAM) is specified, then RENAME(name) must be specified.
Top |
Specifies the system object name of the document to be moved. This parameter can only be specified if FROMDOC(*SYSOBJNAM) is specified.
Top |
Example 1: Adding a Folderless Document
MOVDOC FROMDOC(*SYSOBJNAM) FROMFLR(*NONE) TOFLR(FLR1) RENAME(DOC1) SYSOBJNAM(CNTR192366)
This command, whose system object name is CNTR192366, adds a folderless document to FLR1 and names it DOC1.
Example 2: Moving a Document and Keeping its Name
MOVDOC FROMDOC(DOC1) FROMFLR(FLR1) TOFLR(FLR2) RENAME(*SAME)
This command moves DOC1 from FLR1 to FLR2 and keeps the name DOC1.
Example 3: Moving and Renaming a Document
MOVDOC FROMDOC(DOC1) FROMFLR(FLR1) TOFLR(FLR2) RENAME(DOC2)
This command moves DOC1 from FLR1 to FLR2 and renames it DOC2.
Example 4: Moving a Document and Making It Folderless
MOVDOC FROMDOC(DOC1) FROMFLR(FLR1) TOFLR(*NONE)
This command moves DOC1 from FLR1 and changes it to a folderless document.
Top |
Top |