Restructuring File Items

The REFORMAT and SREFORMAT commands restructure file items and direct the output to backup media, another file, or the original file.

Restructuring file items is useful for rearranging data in file items, for streamlining files by eliminating superfluous data, and for creating cross-reference files.

REFORMAT and SREFORMAT commands do not copy raw data to another file or to backup media, but redirect output. This means that any correlatives and conversions will be applied to the data before it is output. If the user does not want correlatives and conversions applied to the data, but merely to restructure stored (raw) data, create synonyms for the Attribute Definition items that point to the data to be reformatted and leave out the correlatives and conversions. Then use the synonyms in the REFORMAT or SREFORMAT statement.

To reformat an attribute that uses a correlative to derive its data from another file, create a synonym for the Attribute Definition item that includes the correlative (otherwise there will be no data) but does not include any conversions.

After the REFORMAT or SREFORMAT statements are entered, the system displays this prompt:

FILE NAME:

At this point, one of three different operations may be performed:

  1. Transfer items to backup media by typing TAPE. The backup media must already be attached; set the tape or floppy disk record length with the T-ATT command.

  2. Transfer items to another file by typing the name of an existing file as:

  3. [DICT] filename

  4. Transfer items within the same file by pressing ENTER.

The following topics contain detailed information about each of these operations:

Transferring Items to Backup Media

Restructuring Items in a New File

See Also

Using INFO/ACCESS Commands for Special Processing

Printing Labels

Generating Statistics (COUNT, SUM, and STAT)

Copying Items to and from Backup Media