I have completed an SQLite script that identifies individuals in my database who are the spouse of a relative but who are not marked as a spouse of a relative by the new feature in RM10’s Set Relationship tool that identifies spouses of relatives. In my database of 41163 people, my script identifies 57 people who were failed to be marked as a spouse of a relative. This new script relies only on RM10’s own relationship flags and does not rely on any color coding of relationships that I did in RM9 and which have been inherited into RM10.
So far, I see no pattern in the individuals who were missed or any other rhyme or reason for them being missed. There are so relatively few of them that it’s hard to identify them manually. My suspicion is that an RM10 database of any reasonable size is likely to have a few individuals who are failed to be marked as a spouse of a relative - a few but very, very few. I have been suspicious of situations where a relative with several spouses are married to people who also have several spouses. But my database has people who were missed who only had one spouse and who were married to someone who only had one spouse.
I think my script is pretty complete and accurate, but I reserve the right to further fine tune it if I find any issues with it. For whatever it’s worth, the relationship codes in RM10’s database for “Spouse Of” people are identical to the code for the relative. The only difference is that there is a flag field which is turned on for the “Spouse Of” person which is not turned on for the relative.
/*
_bad_set_relationships.sql 7/10/2024 Jerry Bryan
Identifies individuals in an RM10 database who have a missing
"Spouse Of" relationship after running the Set Relationships
tool. The identification of "Spouse Of" reationships such as
"Spouse Of Second Cousin Three Times Removed" is a new feature
in RM10. But there is an apparent bug where the tool misses a
few people. As of yet, no pattern has been identified as to which
people are missed. This script only identifies the people who have
been missed and doesn't fix them.
*/
SELECT F.FatherID, F.MotherID,
Father.Relate1 AS F_Relate1, Father.Relate2 AS F_Relate2, Father.Flags AS F_Flags,
Mother.Relate1 AS M_Relate1, Mother.Relate2 AS M_Relate2, Mother.Flags AS M_Flags
FROM FamilyTable AS F
JOIN PersonTable AS Father ON Father.PersonID = F.FatherID
JOIN PersonTable AS Mother ON Mother.PersonID = F.MotherID
WHERE
(
( ( (F_Relate1 | F_Relate2) != 0) AND ((M_Relate1 | M_Relate2) = 0) )
OR
( ( (F_Relate1 | F_Relate2) = 0) AND ((M_Relate1 | M_Relate2) != 0) )
)
AND
NOT ( (F_Flags | M_Flags) != 0)