Page 1 of 1

Adding relationship to informant in fact sentences

Posted: 14 Aug 2021 00:33
by sbell95
I would like to display the relationship of an informant to the principal person in some of my fact sentences (eg, birth, death, marriage, etc).

For example, my current fact definition for birth is:

Code: Select all

{individual} was born {date} <at {address}> {place} <({age})>. <The informant for the birth was {role=informant}.>
Which outputs the following:
Screenshot 2021-08-14 102733.jpg
Screenshot 2021-08-14 102733.jpg (183.71 KiB) Viewed 1108 times
However, I would like to add something in brackets, like (mother), to show the relationship, if any, between the informant and the principal. In a lot of cases, the informants for births, deaths, etc are family members, but this is not immediately clear when looking at the fact sentence.

Is this possible?

Thanks!

Re: Adding relationship to informant in fact sentences

Posted: 14 Aug 2021 09:51
by tatewise
That is not at all easy.

The biggest problem is that the conditional < chevrons > are only allowed to contain one { code } which must be {role= ... }.
So the {=Relationship(...)} function needed to produce the child to informant relationship cannot be included.
The alternative {=CombineText(...)} function does not support Sentence Template codes such as {role= ... }.

The only method I can think of is to use extra Roles for Father Informant, Mother Informant, etc, in addition to Informant.
Then the Sentence Template would have the following additional codes:
<The informant on the birth certificate was the father {role=father informant}.>
<The informant on the birth certificate was the mother {role=mother informant}.>

You cannot get the word the in front of father or mother to say his or her because that would require another code {individual's} which is not allowed in < chevrons > as I explained above.

You will have to go over your Birth Informat Fact Witnesses and change their Roles to get the above effect.

The above restrictions would be relaxed if Wish List Ref 577 Sentence Template Functions to Replace Codes were implemented. You can Vote for that.

Re: Adding relationship to informant in fact sentences

Posted: 14 Aug 2021 22:37
by sbell95
Thanks for your comprehensive reply, Mike. I will vote for the wish list item.