The HEADERCONTENTS request produces a hexadecimal dump of file headers, row address words, GUARDED or CONTROLLED attribute security information and, optionally, catalog and archive record information. The output is sent to the printer by default.
<headercontents request>
── HEADERCONTENTS ─────────────────────────────────────────────────────► ►─┬─────────────────────────────────────────────────────────────┬──────┤ └─ : ─┬───────────────────────────────────────────────────────┤ │ ┌◄──────────────────────────────────────────────────┐ │ └─┴─┬─ ARCHIVE ─────────────────────────────────────┬─┴─┘ ├─ CATALOGUE ───────────────────────────────────┤ ├─ CONTAINER ─┬─ = <file title> ─┬──────────────┤ ├─ DIRECTORY ─┤ ├─ (CD) ───────┤ ├─ TITLE ─────┘ └─ (CDROM) ────┤ ├─ DATABASE ────┬─ = ──<file title>─────────────┤ ├───────────────┤ │ ├─ NEWDATABASE ─┘ │ ├─ LEVEL ── = ──<integer>───────────────────────┤ ├─<output option>───────────────────────────────┤ ├─ FAMILYNAME ─┬─ = ──<family name>─┬───────────┤ ├─ PACKNAME ───┘ ├─ (CD) ────┤ │ └─ (CDROM) ─┤ ├─ TAPE ── = ─┬─<unit number>───────────────────┤ │ └─<tape name>─┬───────────────────┤ │ ├─ ( ── CD ── ) ────┤ │ └─ ( ── CDROM ── ) ─┤ ├─ TAPEHEADERS ─────────────────────────────────┤ └─ WRAPPEDFILES ────────────────────────────────┘
Explanation
For more information about <output option> refer to “Output Options” earlier in this section.
The following FILEDATA modifiers perform functions such as selecting the disk family or file names to be reported on, and specifying the types of information to be reported for each file. These modifiers are explained under “FILEDATA Modifiers” later in this section.
-
ARCHIVE
-
CATALOGUE
-
CONTAINER
-
DATABASE
-
DIRECTORY
-
FAMILYNAME
-
LEVEL
-
NEWDATABASE
-
PACKNAME
-
TAPE
-
TAPEHEADERS
-
TITLE
-
WRAPPEDFILES
HEADERCONTENTS Example
The following command produces a hexadecimal display of the disk file header for the file (CAD)R/LIST and for any files under that directory on the family XPACK:
RUN *SYSTEM/FILEDATA ("HEADERCONTENTS: FAMILYNAME=XPACK DIRECTORY=(CAD)R/LIST")
HEADERCONTENTS Considerations for Use
The HEADERCONTENTS request can be performed successfully only on a database containing raw headers. The database used for the request contains raw headers if either of the following conditions is true:
-
The database was created for a previous HEADERCONTENTS request, or is newly created for this HEADERCONTENTS request.
-
The RAWHEADERS modifier was included in the request that created the database currently in use.
The circumstances that control whether FILEDATA reuses a database for a request or creates a new database for the request are discussed under “Database Generation and Reuse” earlier in this section.
When a HEADERCONTENTS request that does not create a new database encounters a database that does not contain raw disk file headers, one of following two error messages is printed:
-
If the database used by the program was created by an earlier run of FILEDATA, then this message is printed:
THE DATABASE SPECIFIED DOES NOT CONTAIN RAW HEADERS
-
If the database was created during the same run by an earlier request to FILEDATA, then this message is printed:
THE DATABASE CREATED BY AN EARLIER REQUEST DOES NOT CONTAIN RAW HEADERS
To correct this situation, rerun FILEDATA with the RAWHEADERS modifier in the last database-creating request prior to the HEADERCONTENTS request, or with just the HEADERCONTENTS request on the same files.