SpouseID+Invalid

This page stems from weird behaviour that surfaced in a database that suffered from the initial direct TMG import by RM 6.2.3 which created a single parent family for each child ([|see discussion]). After running the script Merge Duplicate Single Parent Couples, inspection of the results encountered an //empty Family View// when going to certain persons selected in RM Explorer or navigating to them through Family View. What was then discovered was that the SpouseID in the PersonTable was invalid - there was no such couple in the FamilyTable. Setting the SpouseID to 0 cleared the //empty Family View// symptom.

The PersonTable.SpouseID value directs which spouse would be displayed in the Main View when one, other than some default, was selected. Its name is somewhat misleading because it contains the FamilyID in which the selected spouse is tied to the focus person, not the RIN of the spouse. In the case reported above, there were multiple FamilyIDs for a person each with a spouse of RIN 0 and all but one were deleted by the Merge process. The SpouseID could then be left pointing to a now-non-existent FamilyID, resulting in a blank or empty Family View.

=Check for Invalid SpouseIDs= This script is useful for examining the behaviour of SpouseIDs as spouse selection or navigation is executed in RootsMagic.

=Reset Invalid SpouseIDs= This script resets the invalid SpouseIDs reported by the above script to 0.