Calculating Record Size

The AMS RECORDSIZE parameter requires the average and maximum record size, in bytes, of the alternate index record. When you calculate the maximum record size, if the alternate index record spans control intervals, the RECORDSIZE parameter can be larger than the CONTROLINTERVALSIZE. Use the following formula to calculate the maximum record size of spanned records:
  • MAXLRECL=CI/CA x (CISZ - 10)
MAXLRECL is the maximum spanned record size. CI/CA represents the number of control intervals per control area. CA is the number of control areas. CISZ is the quantity control interval size.
Use the following formulas to determine the average size of the alternate index record when the alternate index supports ESDS or KSDS.
  • ESDS:
    • RECSZ= 5 + AIXKL + (n x 4)
  • KSDS:
    • RECSZ= 5 + AIXKL + (n x BCKL)
  • AIXKL is the alternate-key length. (See the KEYS parameter.)
  • BCKL is the base cluster's prime-key length. (You can issue the AMS LISTCAT command to determine the base cluster's prime-key length.)
  • n=1 when the UNIQUEKEY parameter is specified. (In this case, RECSZ is also the maximum record size.)
  • n is equal to the number of base cluster records that have the same alternate index key when NONUNIQUEKEY is specified.
In the preceding examples, the average record size for alternate key STATE was calculated as follows:
  • 5 + 2 + (3 x 4)= 19 for the ESDS
  • 5 + 2 + (3 x 9)= 34 for the KSDS
Specifying the same value for average and maximum identifies the records as fixed length. See IBM Documentation for more information about calculating record size.