This document explains the format of the SAI files. SAI files are used in the database as a table of contents. Every non-deleted record in the database will have a record in the SAI file. SAI records are all the same size, so it is very easy to modify the contents of this file in place, including removing and reordering entries.
A record in a SAI file consists of a pointer to a MDB record, and to its associated PAI module (if applicable). The pointer to the PAI module does not point to the start of the module, however, but to the location of the first entry within the module. See the PAI file format for more information.
Word Offset | Size (words) | Description |
---|---|---|
0 | 2 | Signature, "0x05181971" |
2 | 2 | Reserved (zero by default) |
4 | 1 | Number of entries (N) |
5 | 3 | Reserved (zero by default) |
8 | 4 | 0x00000000, 0x00000000 (looks like an empty record) |
12 | 2 | MDB pointer for record 1 |
14 | 2 | PAI pointer for record 1 |
... | ... | ... |
12+4*(i-1) | 2 | MDB pointer for record i |
14+4*(i-1) | 2 | PAI pointer for record i |
... | ... | ... |
12+4*(N-1) | 2 | MDB pointer for record N |
14+4*(N-1) | 2 | PAI pointer for record N |
12+4*N | 4 | 0x00000000, 0x00000000 (looks like an empty record) |