Learn how to copy file attributes using the hierarchical file system
(HFS).
When you copy files using the hierarchical file system between
QOPT and QDLS file systems, the target file is assigned either default file
attributes or the file attributes of the source file. This depends on the
value you specify for the copy attributes (CPYATR) global value on the Change
Optical Attributes (CHGOPTA) command.
When the CPYATR global value is
specified as *NO on the CHGOPTA command, default file attributes are created
for files that are copied between the QOPT and QDLS file systems.
When
the CPYATR global value is specified as *YES on the CHGOPTA command, file
attributes from the source file are copied to the target file for copies between
the QOPT and QDLS file system.
Copying attributes from QOPT to QDLS
In copies or
moves from QOPT to QDLS, the following default attributes are created:
- Standard file attributes:
- Creation date and time is set to the current date and time.
- Modification date and time is set to the current date and time.
- Access date and time is set to the current date and time.
- The QFILATTR standard attribute is set to 00000;
the file is not read-only, the file is not hidden, the file is not a system
file, the file is not a directory, and the file has not changed since it was
last archived or created.
- DIA document attributes:
- DIA.CA04C700 (text description) is set to the file name.
- DIA.CA04C701 (profile GCID) is set to code page 697 and character set
500.
- DIA.CA04C706 (file type) is set to 000E (PC file).
- DIA.CA04C720 (library assigned document name) is assigned to represent
this file.
- DIA.CA04C708 (last changed date and time) is set to the current date and
time.
- DIA.CA04C707 (creation date and time) is set to the current date and time.
- DIA.CA04C710 (NLS information) is set to the language ID and country or
region ID of the job.
- DIA.CA04C740 (file date and time) is set to the current date and time.
- No user-defined extended attributes are copied.
The file name (QNAME) and file size (QFILSIZE) are maintained.