Listing File Characteristics

You can use the :LISTFILE command to see what the c haracteristics of a ￿le are. :LISTFILE provides the following information:

File names and structure of permanen t disc ￿les

Various levels of detail about eac h ￿le, depending on the user's capability on the system

Number of records in the ￿le Number of extents Maximum number of extents Records per blockThe :FILE Command

The :FILE command determines ho w a ￿le will be accessed. Y ou can use :FILE to describe any of the characteristics a vailable with HPFOPEN , FOPEN , or :BUILD , but you cannot actually create a ￿le with the :FILE command. While HPFOPEN , FOPEN , and :BUILD physically allocate space for a ￿le and de￿ne its c haracteristics, the :FILE command can de￿ne only ho w a ￿le will be accessed at run time.

FILE sets up an environment for the ￿le at run time and speci￿es the ￿le's attributes when it is opened. When y ou invoke a :FILE command, the Command In terpreter checks it for syntactic correctness and sa ves a ￿le equation in a job or session table for use when the referenced ￿le is opened. Another process, suc h as an HPFOPEN or FOPEN , performed on the referenced ￿le activates the information speci￿ed in the :FILE command. To be e￿ective, the :FILE command must be invoked before the ￿le is accessed because the parameters speci￿ed for :FILE take e￿ect when the ￿le is accessed. They remain in e￿ect un til one of the follo wing conditions occurs:

The job or session ends. A :RESET command is invoked.

The parameters are o verridden by another :FILE command invoked for the same formal ￿le designator.

File equations are k ept track of by a table created for the job or session. Y ou can use the MPE/iX commands :LISTEQ to see a list of the curren t ￿le equations and and :LISTFTEMP to see a list of the curren t temporary ￿le names.

For an example of using the :FILE command and a comparison of the parameters for HPFOPEN , FOPEN , and :FILE, refer to the MPE/iX Commands Reference Manual Volumes 1 and 2 (32650-90003 and 32650-90364) and Accessing Files Pr ogrammer's Guide (32650-90017).

File System 6-29