Currently, foreign keys are treated as ulong. While it seems to work on .dat, the correct type of field is (ptr_size + ptr_size).
The first pointer is an actual row index in foreign dat file, the second pointer is always NULL.
I propose to add new field type foreignkey (or genericgeneric).
Specification can be auto updated thanks to the naming conventions
if (string.endsWith(field.name, "Keys") && field.type == "ref|list|ulong") {
field.type = "ref|list|foreignkey"
}
if (string.endsWith(field.name, "Key") && field.type == "ulong") {
field.type = "foreignkey"
}
Here's example from BaseItemTypes: .dat at top, .dat64 at bottom.


Currently, foreign keys are treated as
ulong. While it seems to work on .dat, the correct type of field is(ptr_size + ptr_size).The first pointer is an actual row index in foreign dat file, the second pointer is always NULL.
I propose to add new field type
foreignkey(orgenericgeneric).Specification can be auto updated thanks to the naming conventions
Here's example from
BaseItemTypes: .dat at top, .dat64 at bottom.