Options:
E -If an error occurs, do not abort the procedure
R -(Form 2 only) Suppress overstore notification
X -Suppress the command response
Y -Do not alter the command answer cells
Answers:
Ctl.Ans1 =1 if successful, 0 if not
Ctl.Ans2 =Zero
Ctl.Ans3 =Zero
Notes:
FROM and TO are optional and are allowed for readability. The source of the copy is always name1 and the target is always name2.
If name2 did not previously exist it is created by the COPY command.
Note the asterisks immediatly in front of (no blank) the file names in forms 2 and 3. That is how we know they are files and not definition names in the Catalog. The file names can be full path names. If the path is omitted, the current directory is assumed.
When COPY is executed in a procedure there is no overstore notification when the target is a definition name.
Use of the E option means if an error occurs, do not print an error message and do not terminate the current procedure. The application must check the %status variable to determine success or failure.
Copying definitions from another Catalog
Form 4 allows you to copy a definition that exists in another Catalog into your own. Just supply the full path name of the Application Interface where the source definition is known. This name is included in parenthesis just after the source definition name. There is a space between the source name and the parenthetical insert that contains the AI name.