Expression help please
Posted: 13 Mar 2021 19:57
Where I have a death certificate/registration for an individual I create a source whose short title takes the form "D. Cert., [SURNAME], [given names] [year]". I should note at this point the name used in the title is the name recorded on the death certificate, so it may not match the birth name of the individual.
I am using the expression =ContainsText(%INDI.DEAT.SOUR>ABBR%,"D. Reg.",STD) to display an icon on charts against individuals who have a date of death that cites such a source. That enables me to see at a glance where in a tree I have already found a death registration and where I still need to look.
Generally it works well enough, but I am getting some false positives. There are a few individuals for whom I do not yet have an actual date of death, but I have a "before date" derived from their spouse's death certificate (i.e. the spouse is described on their death certificate as "the widow of X", so I know the individual was dead before their spouse's date of death and record it accordingly). Consequently, a death fact is created for the individual that records a "before" date and cites their spouse's death certificate. This wrongly triggers the display of the icon on the chart.
I don't want to not record the before date for the individual's death. Is there a way to tweak the expression, so that it is not wrongly triggered in the scenario I just described? I guess it would I either need somehow to exclude date ranges containing "before", or else check if the short title of the source being cited matches that particular individual's name (but that might be complicated, see first paragraph). Either way, I don't know how to achieve what I need.
Can anyone give me any pointers?
I am using the expression =ContainsText(%INDI.DEAT.SOUR>ABBR%,"D. Reg.",STD) to display an icon on charts against individuals who have a date of death that cites such a source. That enables me to see at a glance where in a tree I have already found a death registration and where I still need to look.
Generally it works well enough, but I am getting some false positives. There are a few individuals for whom I do not yet have an actual date of death, but I have a "before date" derived from their spouse's death certificate (i.e. the spouse is described on their death certificate as "the widow of X", so I know the individual was dead before their spouse's date of death and record it accordingly). Consequently, a death fact is created for the individual that records a "before" date and cites their spouse's death certificate. This wrongly triggers the display of the icon on the chart.
I don't want to not record the before date for the individual's death. Is there a way to tweak the expression, so that it is not wrongly triggered in the scenario I just described? I guess it would I either need somehow to exclude date ranges containing "before", or else check if the short title of the source being cited matches that particular individual's name (but that might be complicated, see first paragraph). Either way, I don't know how to achieve what I need.
Can anyone give me any pointers?