To make an indexed sequential copy of the supplied sequential file:
- In Classic Data File Tools, click
Tools > Convert.
- To supply the input file details, click the
Browse button and use the
Open dialog box to select the file
datavseq.dat from the
DataToolsDemo project directory.
The details for the input file and the output file are initialized with the information read from the file header for
datavseq.dat.
- In the lower part of the dialog box, enter the following details for the output file (leave the remaining fields unchanged):
Filename:
|
staff.dat
|
Format:
|
Micro Focus
|
Organization:
|
Indexed Sequential
|
- Click
Define Keys; then click
Insert Key.
The field to be used as the key is at the beginning of the record, and is seven bytes long.
- Set
Key Offset to
0 and
Key Length to
7; then click
OK.
- Click
Convert.
- Click
OK on the message saying the data file conversion is complete.
The Data File Convert dialog box reappears so you can convert more files.
- Click
Cancel.
- Check the
DataToolsDemo project directory. The Data File Converter has created the new files
staff.dat, which contains the record data, and
staff.idx, which contains the record key information.