Initialize Physical File Mbr (INZPFM)
|Where allowed to run: All environments (*ALL)
The Initialize Physical File Member (INZPFM) command initializes records in a member of a physical file to the specified type of record (either default or deleted records). If the initialized member is empty, records are added and initialized to the specified type; if the member is not empty, records of the specified type are added to the member. As many records are added as is necessary to make the total record count specified.
- This command is conditionally threadsafe. In multithreaded jobs, this command is not threadsafe and fails for Distributed Data Management (DDM) files of type *SNA.
|FILE||Physical file||Qualified object name||Required, Positional 1|
|Qualifier 1: Physical file||Name|
|Qualifier 2: Library||Name, *LIBL, *CURLIB|
|MBR||Member||Name, *FIRST, *LAST||Optional, Positional 2|
|RECORDS||Initialize records as||*DFT, *DLT||Optional, Positional 3|
|TOTRCDS||Total number of records||1-4294967288, *NXTINCR||Optional|
Physical file (FILE)
Specifies the physical file that contains the member to be initialized.
This is a required parameter.
Qualifier 1: Physical file
- Specify the name of physical file.
Qualifier 2: Library
- All libraries in the library list for the current thread are searched until the first match is found.
- The current library for the job is used to locate the file. If no library is specified as the current library, QGPL is used.
- Specify the name of the library to be searched.
Specifies the file member to be initialized.
- The first member of the specified file is used.
- The last member of the specified physical file is initialized.
- Specify the name of the physical file member to be initialized.
Initialize records as (RECORDS)
Specifies the type of records that are initialized or added to the specified member. The records in the member are initialized as default records or deleted records.
- The records in the member are initialized as default records. If a default value was specified in the DDS (DFT keyword) for a field, that field is initialized to the specified default; otherwise, all numeric fields are initialized to zeros and all character fields are initialized to blanks.
- The records in the member are initialized as deleted records. The records are not eligible for access, but simply hold a place in the file. Deleted records are changed to reuse the deleted space.
Total number of records (TOTRCDS)
Specifies the total number of records in the member after it is initialized. If the value specified in this parameter causes the size of the file to be larger than the size specified when the file was created, a message is sent to the system operator's message queue (QSYSOPR). The operator can either continue or cancel the operation.
- The number of records in the member is increased to extend the file to the next allocation amount added. If the member is empty, records are added to meet the initial allocation specified for the member. *NXTINCR is not valid if *NOMAX was specified for the Member size (SIZE) parameter, when the file is created.
- Specify the total number of records you want the the member to have. If the number of existing records in the member already meets or is larger than this number, no records are initialized; if the number is less than that specified, enough records are initialized to equal the total specified.
INZPFM FILE(*CURLIB/INV) TOTRCDS(12000)
This command initializes as many as 12,000 records in the first member of the physical file named INV in the job's current library *CURLIB. Only the number of records are added that brings the total to 12,000 records in the member. Any records that are added are initialized to the default format. If a default value is specified in the DDS (DFT keyword) for a field, that field is initialized to the specified default; otherwise, all numeric fields are initialized to zeros and all character fields are initialized to blanks.
- Member &2 already in use.
- Cannot initialize member &2 with default records.
- TOTRCDS parameter value either missing or too small.
- File &1 in library &3 contains no members.
- Referential constraint error processing member &2.
- File &1 in &3 not allowed on command.
- No authority to clear, initialize, or copy member &2.
- Check constraint error processing member &2.
- Initialize or copy of member &2 canceled.
- Member &2 not found.
- File &1 in library &3 not found.
- Increments not allowed for member &2.
- Member &2 not cleared or initialized.
- New records need too much space for member &2.
- File &1 in library &3 in use.
- Triggers prevent requested operation.
- Member &2 saved with STG(*FREE).
- Operation on member &2 ended. Entry cannot be journaled.
- Cannot clear or initialize DDM file &1 in &3.
- Member &2 not initialized.
- Distributed file error, reason code &3.
- Distributed file error, level ID mismatch
- Operation was not valid for database file &1.
- Object &2 in library &3 not found.
- Library &1 not found.
- Not authorized to use library &1.