Previous Topic: Specify the File Key

Next Topic: Data Set Positioning and Generic Retrieval

Work with Data

As with other NCL functions, data manipulated by file processing is usually maintained in tokenized form (for example, as NCL variables). The &FILE verb also enables data to be maintained in an MDO, but only for mapped format file processing. A typical NCL procedure might accept input from a full-screen panel in a series of tokens or variables and then add this data to a UDB. Alternately, it can receive data from another application using APPC into an MDO, and then add this data to a mapped format UDB.

The physical representation of the data on the UDB depends on its format:

When data is retrieved from an unmapped format UDB, NCL again makes no attempt to identify individual fields within the record. The entire record is read from the UDB and then split into as many variables as are necessary to hold the data that has been read. Alternatively, the user can indicate how many bytes of data from the record are to be placed into each variable on the &FILE GET statement.

When data is retrieved from a mapped format UDB it is placed into an MDO unchanged from the way it existed on the file. It is also possible to specify the name of a map on the file verb which will be attached to MDO when data is placed into it. When writing to a file using mapped format, the contents of the MDO are simply placed on the file as they are.