I've been using the Period tab on the Date Entry Assistant for things like occupation and residence. The sentence sound normal enough if I have the start time and not end time, but it could be better. From 1739 he was a road surveyor OR He was a road surveyor from 1739. To me it would sound better to say: Starting in 1739 he was a road surveyor OR In 1739 he started his career as a road surveyor OR He started as a road surveyor in 1739. I could use the single date and add after, but to me that sounds like the date is uncertain and that if was sometime after 1739 when he became a road surveyor.
Then if I have the end date and no start date I get: To 1750 he lived in Virginia. Until 1750 would sound better. Until 1750 he lived in Virginia OR He lived in Virginia until 1750.
Is there a way for me to switch out this?
Maybe just get the number and I can add the wording in the sentence template.
With a single date there is {%FACT.DATE:MONTH_NAME%} {%FACT.DATE:DAY%},{%FACT.DATE:YEAR%} would give me the date without the preposition, but that returns nothing, likely since it needs to identify if I want the starting or ending date.
Any suggestions?
* Partial Date Period in sentence
- tatewise
- Megastar
- Posts: 27078
- Joined: 25 May 2010 11:00
- Family Historian: V7
- Location: Torbay, Devon, UK
- Contact:
Re: Partial Date Period in sentence
Customizing the display of Period Dates in Sentence Templates involves some advanced techniques.
The Date Qualifiers such as DAY and YEAR that you mentioned are explained in the Date Formats Help page.
There you will find that DAY and YEAR only return values for simple dates.
To manage more complex dates involves the XDATE1, XDATE2 and XDATETYPE qualifiers at the bottom of the page.
In your From Period Date case, XDATETYPE = "From" and XDATE1 will provide the From Date without any prefix.
So you can use the TextIf(...) function to replace From with After.
e.g.
{=TextIf( %FACT.DATE:XDATETYPE% = "From", Text( "After " . %FACT.DATE:XDATE1% ), %FACT.DATE% )}
displays After <date> for From Period Dates or the entire fact date otherwise.
{=TextIf( %FACT.DATE:XDATETYPE% = "To", Text( "Until " . %FACT.DATE:XDATE2% ), %FACT.DATE% )}
displays Until <date> for To Period Dates or the entire fact date otherwise.
Combining those two gives:
{=TextIf( %FACT.DATE:XDATETYPE% = "From", Text( "After " . %FACT.DATE:XDATE1% ),
TextIf( %FACT.DATE:XDATETYPE% = "To", Text( "Until " . %FACT.DATE:XDATE2% ), %FACT.DATE% ) )}
The Date Qualifiers such as DAY and YEAR that you mentioned are explained in the Date Formats Help page.
There you will find that DAY and YEAR only return values for simple dates.
To manage more complex dates involves the XDATE1, XDATE2 and XDATETYPE qualifiers at the bottom of the page.
In your From Period Date case, XDATETYPE = "From" and XDATE1 will provide the From Date without any prefix.
So you can use the TextIf(...) function to replace From with After.
e.g.
{=TextIf( %FACT.DATE:XDATETYPE% = "From", Text( "After " . %FACT.DATE:XDATE1% ), %FACT.DATE% )}
displays After <date> for From Period Dates or the entire fact date otherwise.
{=TextIf( %FACT.DATE:XDATETYPE% = "To", Text( "Until " . %FACT.DATE:XDATE2% ), %FACT.DATE% )}
displays Until <date> for To Period Dates or the entire fact date otherwise.
Combining those two gives:
{=TextIf( %FACT.DATE:XDATETYPE% = "From", Text( "After " . %FACT.DATE:XDATE1% ),
TextIf( %FACT.DATE:XDATETYPE% = "To", Text( "Until " . %FACT.DATE:XDATE2% ), %FACT.DATE% ) )}
Mike Tate ~ researching the Tate and Scott family history ~ tatewise ancestry
Re: Partial Date Period in sentence
Is part of the problem the underlying inability to adequately define what we put in date fields and the incompatibility of different date inputs if we want FH to do more than just data storage - rather than off-load not just sentence construction but actual Family History writing to another program such as a word-processor?
Compared to other programs we can already do much - such as "Q4 1852", but we cannot (as far as I know) enter say a residence fact with date "from prior to or about Q4 1852 to prior to 16 May 1858"; where say Q4 1852 is a census date giving a first point in time (assuming a permanent residence) - but not a precise first date; and where say 16 May 1858 is a burial date.
The trouble with sentence construction is that there are programmed in implicit assumptions about what the date actually means.
Compared to other programs we can already do much - such as "Q4 1852", but we cannot (as far as I know) enter say a residence fact with date "from prior to or about Q4 1852 to prior to 16 May 1858"; where say Q4 1852 is a census date giving a first point in time (assuming a permanent residence) - but not a precise first date; and where say 16 May 1858 is a burial date.
The trouble with sentence construction is that there are programmed in implicit assumptions about what the date actually means.
David
Running FH 6.2.7. Under Wine on Linux (Ubuntu 22.04 LTS + LXDE 11)
Running FH 6.2.7. Under Wine on Linux (Ubuntu 22.04 LTS + LXDE 11)
- tatewise
- Megastar
- Posts: 27078
- Joined: 25 May 2010 11:00
- Family Historian: V7
- Location: Torbay, Devon, UK
- Contact:
Re: Partial Date Period in sentence
David, FH is constrained to use GEDCOM formats for Dates, as are many other genealogy products.
If that were not so then migrating data from product to product would be even more difficult than it is now.
So the Date box only allows specific prescribed formats.
There are some interesting examples in your posting.
Q4 1852 is a census date giving a first point in time
A census date would never be Q4 1852 because a Census Event occurs on a specific single date.
Q4 1852 is more likely to be a BMD Registration quarter and is actually a Range Date 'btw 1 Sep 1852 and 31 Dec 1852'.
If you really want to say such as "from prior to or about 1852 to prior to 16 May 1858" in a Narrative Sentence then that is possible using a Fact Specific Sentence Template expression such as :
"from prior to or about {%FACT.DATE.XDATE1%} to prior to {%FACT.DATE.XDATE2%}"
If that were not so then migrating data from product to product would be even more difficult than it is now.
So the Date box only allows specific prescribed formats.
There are some interesting examples in your posting.
Q4 1852 is a census date giving a first point in time
A census date would never be Q4 1852 because a Census Event occurs on a specific single date.
Q4 1852 is more likely to be a BMD Registration quarter and is actually a Range Date 'btw 1 Sep 1852 and 31 Dec 1852'.
If you really want to say such as "from prior to or about 1852 to prior to 16 May 1858" in a Narrative Sentence then that is possible using a Fact Specific Sentence Template expression such as :
"from prior to or about {%FACT.DATE.XDATE1%} to prior to {%FACT.DATE.XDATE2%}"
Mike Tate ~ researching the Tate and Scott family history ~ tatewise ancestry
Re: Partial Date Period in sentence
Ah, Brain fog!
David
Running FH 6.2.7. Under Wine on Linux (Ubuntu 22.04 LTS + LXDE 11)
Running FH 6.2.7. Under Wine on Linux (Ubuntu 22.04 LTS + LXDE 11)
- AdrianBruce
- Megastar
- Posts: 1961
- Joined: 09 Aug 2003 21:02
- Family Historian: V7
- Location: South Cheshire
- Contact:
Re: Partial Date Period in sentence
Perhaps more to the point is that the date is capable of being interpreted by the human writer and reader in several ways. For instance, take "From 1 April 1925..." Does that include or exclude 1 April? I'm sure that lots of people will immediately say, "Include of course..." They are probably not mathematicians etc, who'd ask whether it's "greater than" or "greater than or equal" that is meant.
If there's any doubt, I tend to make it explicit in the notes for the event / attribute.
When the reality is that we need constructions of the sort that require qualifications not present in GEDCOM (e.g. "From about 1927..."), then I'll set the GEDCOM date to something as close as possible (e.g. "From 1927") but, I'll write the full text in the Note and, in my narrative report, suppress the generated sentence by replacing that single sentence with
<para>{note}
That will allow any and every verbal contortion to appear in the note and thence, the narrative report.
Adrian