Other users have a similar requirement, and it has been suggested that what is needed is some way to indicate which
Occupation entry is the
Primary one, but nothing has been provided yet.
However, there are a number of ways to achieve what you ask for.
(1) Custom Attribute
You could create a
Custom Attribute for
Primary Occupation and then the
Text Scheme would simply display that
Custom Attribute as per Adrian's suggestion above.
The
Template would be similar to:
Code: Select all
Occup. %INDI._ATTR-PRIMARY_OCCUPATION%
However, you may also want to exclude that
Custom Attribute from
Reports to avoid duplication.
(2) Unique Occupation
Where an
Individual has multiple
Occupation Attributes there needs to be something to make one of them unique.
Two suggestions are to use the
Cause field or the
Source Note field, neither of which are likely to be used in practice for anything else.
You will have to use the
All tab to add a value such as
Primary to either such field for the chosen
Occupation.
Then the
Text Scheme must selectively display just that
Occupation by using a
Template such as:
Code: Select all
Occup. =TextIf(%INDI.OCCU.CAUS%="Primary",%INDI.OCCU%,TextIf(%INDI.OCCU[2].CAUS%="Primary",%INDI.OCCU[2]%,TextIf(%INDI.OCCU[3].CAUS%="Primary",%INDI.OCCU[3]%,)))
Simply use
SOUR2 instead of
CAUS to test the
Source Note instead of
Cause field.
You will have to keep nesting
TextIf() functions until enough
Occupations are supported.
If there are a lot, the
Template may get too long, and then you will need to repeat the
Text Scheme item for the larger indexes.
Explanation:
The basic
=TextIf( condition, true-text, false-text ) function is:
=TextIf(%INDI.OCCU.CAUS%="Prime",%INDI.OCCU%,)
In this case if the
1st Occupation is
Prime then it is displayed, otherwise, nothing is displayed.
The blank
false-text parameter must be replaced by a nested
TextIf() function:
=TextIf(%INDI.OCCU.CAUS%="Prime",%INDI.OCCU%,TextIf(%INDI.OCCU[2].CAUS%="Prime",%INDI.OCCU[2]%,))
Now if the
1st Occupation is NOT
Prime, but the
2nd Occupation is
Prime then it is displayed.
This pattern can be repeated for the
3rd,
4th, etc,
Occupation until the
Template becomes too long.