Calculating the Logical Record Length
You must supply the logical record length to the Create operation (14). The logical record length is the number of bytes of fixed-length data in the file. To obtain this value, calculate how many bytes of data you need to store in the fixed-length portion of each record.
For example, the following table shows how the data bytes in the example Employees file are added together to obtain a logical record length:
1
4
4
In calculating the logical record length, you do not count variable-length data, because variable-length information is stored apart from the fixed-length record in the file (on variable pages).
The maximum logical record length depends on the file format as defined in Table 16.
page size minus 10 minus 2 (record overhead)
page size minus 8 minus 2 (record overhead)
page size minus 6 minus 2 (record overhead)
page size minus 6 minus 2 (record overhead)
Note: The record overhead in these examples is for a fixed-length record (not a variable record) without record compression.