Data
The commands in the Data menu allow you to import, export, and copy records in data files. You can also recover data after a system failure with the Roll Forward feature. See Roll Forward Command for a discussion of Roll Forward.
Importing and Exporting ASCII File Format
When you save data, records in the ASCII file have the following format. You can use an ASCII text editor to create files that you can load, as long as they adhere to these specifications. Note that most text editors do not support editing binary data.
For files with fixed-length records, the length you specify should equal the record length of the data file.
For files with variable-length records, the length you specify must be at least as long as the fixed-record length of the data file.
Figure 30 shows the correct format for records in the input ASCII file. For this example, the data file has a defined record length of 40 bytes.
Figure 30 Format for Records in Input Sequential Files
Data Tasks
You can perform the following data tasks with the Maintenance utility:
Importing Records From an ASCII File
You can use the Maintenance utility to import records from an ASCII file to a standard data file. This operation does not perform any conversions on the data. You can create an import file using a text editor or the Maintenance utility (see Exporting Records to an ASCII File).
1
Click Data > Load from the main menu. The Load dialog box appears.
Figure 31 Load Dialog Box
The ASCII file you specify must adhere to the specifications explained in Importing and Exporting ASCII File Format. The record length of the standard data file you specify must be compatible with the records in the ASCII file.
2
Click Execute to import the records.
While importing data, the Maintenance utility shows the number of records being imported, the percentage of records imported, and a status message. You can continue working in the Maintenance utility (for example, you can open another Load dialog box).
Exporting Records to an ASCII File
You can use the Maintenance utility to export records from a data file to an ASCII file.
1
Click Data > Save from the main menu. The Save Data dialog box appears.
Figure 32 Save Data Dialog Box
2
In the Save Data dialog box, specify the following options.
Internal Index #:
Uses the specified key number. Click Refresh Index List to update the available indexes if you change file in the From MicroKernel File box.
External Index File:
Uses the specified external index. (To create an external index, refer to Creating Indexes.)
 
3
Click Execute to export the data. The Maintenance utility creates the specified ASCII file using the format described in Importing and Exporting ASCII File Format. You can then edit the ASCII file and use the Load command to import the edited text to another standard data file
Copying Records Between Data Files
You can use the Maintenance utility to copy data from one MicroKernel data file to another. The record lengths for both data files you specify must be the same.
1
Click Data > Copy from the main menu. The Copy Data dialog box appears.
Figure 33 Copy Data Dialog Box
2
Enter the name of the file you want to copy in the From MicroKernel File box and then specify the path where you want to copy the file in the To MicroKernel File box.
The record lengths for both data files you specify must be the same.
Recovering (Roll Forward) Changes to a Data File
See the Logging, Backup, and Restore.