Display File Field Description (DSPFFD)
Where allowed to run: All environments (*ALL)
Threadsafe: NoParameters
Examples
Error messagesThe Display File Field Description (DSPFFD) command shows, prints, or places in a database file field-level information for one or more files in a specific library or all the libraries to which the user has access.
If the information is put in a database file, the database file will have a record format named QWHDRFFD. The fields in record format QWHDRFFD are the same as the fields in the IBM-supplied format QWHDRFFD in file QADSPFFD in the library QSYS. The following information is contained in the database file:
- For each file specified in the command, the database record contains:
- The name of the file, the name of the library containing the file, the file type, and file member
- The file creation date and the number of record formats in the file
- The name of the record format used by the file, the format level identifier, the format text description, the format record length, and the number of fields in the format
- The information retrieval date and time
- For each field in the record format, the record also contains the following, if applicable:
- The field name and external field name
- The type and length of the field
- For fields referencing other fields, the name of the referenced file, record format, and field; if any attributes of the referenced field were changed, the attribute type is given
- The edit code, edit word, and column headings associated with the field
- A signal of whether validity checking is performed on the field
- The validity check message identifier, the message file, and the library
- The use of the field
To create an OUTFILE, the user must have object operational authority to the Create Physical File (CRTPF) command and add authority to the library. To use an existing OUTFILE, the user must have object operational and add authority to the file. The user must also have object management and delete authority if *REPLACE is specified on the OUTMBR parameter.
Restrictions:
- Before users can display each file specified, they must have object operational authority for the file.
- Also, of the libraries specified by the library qualifier, only the libraries for which the user has read authority are searched.
Top
Parameters
Keyword Description Choices Notes FILE File Qualified object name Required, Positional 1 Qualifier 1: File Generic name, name, *ALL Qualifier 2: Library Name, *LIBL, *CURLIB, *USRLIBL, *ALLUSR, *ALL OUTPUT Output *, *PRINT, *OUTFILE Optional, Positional 2 OUTFILE File to receive output Qualified object name Optional Qualifier 1: File to receive output Name Qualifier 2: Library Name, *LIBL, *CURLIB OUTMBR Output member options Element list Optional Element 1: Member to receive output Name, *FIRST Element 2: Replace or add records *REPLACE, *ADD SYSTEM System *LCL, *RMT, *ALL Optional
Top
File (FILE)
Specifies the name and library of the files.
This is a required parameter.
The possible values for file names are:
- file-name
- Specify the full name of a file. Only information for the specified file is returned.
- generic*-file-name
- Specify a generic name. Information is provided for all files whose names begin with the specified characters.
- *ALL
- All files in the library or libraries have their information shown.
Qualifier 2: Library
- *LIBL
- All libraries in the library list for the current thread are searched until the first match is found.
- *CURLIB
- The current library for the thread is searched. If no library is specified as the current library for the thread, the QGPL library is searched.
- *USRLIBL
- If a current library entry exists in the library list for the current thread, the current library and the libraries in the user portion of the library list are searched. If there is no current library entry, only the libraries in the user portion of the library list are searched.
- *ALLUSR
- All user libraries are searched. All libraries with names that do not begin with the letter Q are searched except for the following:
#CGULIB #DSULIB #SEULIB #COBLIB #RPGLIB #DFULIB #SDALIBAlthough the following Qxxx libraries are provided by IBM, they typically contain user data that changes frequently. Therefore, these libraries are considered user libraries and are also searched:
QDSNX QRCLxxxxx QUSRIJS QUSRVxRxMx QGPL QSRVAGT QUSRINFSKR QGPL38 QSYS2 QUSRNOTES QMGTC QSYS2xxxxx QUSROND QMGTC2 QS36F QUSRPOSGS QMPGDATA QUSER38 QUSRPOSSA QMQMDATA QUSRADSM QUSRPYMSVR QMQMPROC QUSRBRM QUSRRDARS QPFRDATA QUSRDIRCL QUSRSYS QRCL QUSRDIRDB QUSRVI
- 'xxxxx' is the number of a primary auxiliary storage pool (ASP).
- A different library name, in the format QUSRVxRxMx, can be created by the user for each previous release supported by IBM to contain any user commands to be compiled in a CL program for the previous release. For the QUSRVxRxMx user library, VxRxMx is the version, release, and modification level of a previous release that IBM continues to support.
- *ALL
- All libraries in the system, including QSYS, are searched.
- name
- Specify the name of the library to be searched.
Top
Output (OUTPUT)
Specifies whether the output from the command is displayed at the requesting work station or printed with the job's spooled output.
- *
- The output is displayed (if requested by an interactive job) or printed with the job's spooled output (if requested by a batch job).
- The output is printed with the job's spooled output.
- *OUTFILE
- The output is directed to the database output file specified on the File to receive output prompt (OUTFILE parameter).
Top
File to receive output (OUTFILE)
Specifies the name and library of the database output file to which the output of the command is directed. If the file does not exist, this command creates a database output file in the specified library.
The possible library values are:
- *LIBL
- All libraries in the library list for the current thread are searched until the first match is found.
- *CURLIB
- The current library for the job is used to locate the file. If no current entry exists in the library list, QGPL is used.
- library-name
- Specify the name of the library where the file is located.
The outfile format must be the same as QWHDRFFD of system file QADSPFFD. For more information on the outfile format, refer to Database information in the iSeries Information Center at http://www.ibm.com/eserver/iseries/infocenter book.
Top
Output member options (OUTMBR)
Specifies the name of the database file member that receives the output of the command.
The possible values are:
- *FIRST
- The first member in the file receives the output. If no members exist in the file, the system creates a member with the name of the file specified in the File to receive output prompt (OUTFILE parameter).
- member-name
- Specify the name of the file member that receives the output. If the name does not exist, the system creates it.
The possible values for how information is stored are:
- *REPLACE
- The output data replaces any existing records in the specified file member.
- *ADD
- The output data is added to the end of existing records in the specified file member.
Top
System (SYSTEM)
Specifies whether the information that is returned is about files on the local system or files on remote systems.
The possible values are:
- *LCL
- The information returned is about local files only.
- *RMT
- The information returned is about remote files only.
- *ALL
- The information returned is about both local and remote files.
Top
Examples
Example 1: Displaying Information About a File on the Local System
DSPFFD FILE(LIB1/FILE2)This command shows the field-level information about file FILE2 in LIB1 on the local system. The information is shown at the work station where the command was entered.
Example 2: Displaying Information About Files on the Local and Remote Systems
DSPFFD FILE(*ALL/*ALL) SYSTEM(*ALL)This command shows the field-level information of all files in all libraries authorized to the user on the local system and on all remote systems. For distributed data management files, the display shows only information about the remote file that is named on the RMTFILE parameter of the CRTDDMF command. The information is shown at the work station where the command was entered.
Example 3: Directing Output to a Database File
DSPFFD FILE(QGPL/FLDREF) OUTPUT(*OUTFILE) OUTFILE(QGPL/FLDREFX)This command puts the field-level information for the file FLDREF in the QGPL library on the local system into a database file named FLDREFX in the general purpose library, QGPL. The FLDREFX file in the QGPL library can then be processed by a program.
Top
Error messages
*ESCAPE Messages
- CPF3012
- File &1 in library &2 not found.
- CPF3014
- No file specified as &1 in &2 can be displayed.
- CPF3024
- File &1 not allowed for SYSTEM(&3).
- CPF3052
- Description for file &1 not available.
- CPF3061
- Record format &3 not found for outfile &1.
- CPF3063
- Output file &1 in &2 not physical file.
- CPF3064
- Library &1 not found.
- CPF3066
- Error creating output file &1 in &2.
- CPF3067
- Error while opening file &1 in &2.
- CPF3068
- Error while writing to file &1 in &2.
- CPF3069
- Error while closing file &1 in &2.
- CPF3070
- Error creating member &3 in file &1.
- CPF3072
- File &1 in &2 is a system file.
- CPF3074
- Not authorized to library &1.
- CPF3075
- Library &1 not available.
- CPF3076
- Error occurred when on display.
- CPF3077
- Error occurred when canceling display.
- CPF3084
- Error clearing member &3 in file &1.
- CPF326B
- Damage to file &1 in library &2.
- CPF9851
- Overflow value for file &1 in &2 too small.
- CPF9852
- Page size too narrow for file &1 in &2.
- CPF9899
- Error occurred during processing of command.
Top