* Query - Possible Common Ancestors

Questions regarding use of any Version of Family Historian. Please ensure you have set your Version of Family Historian in your Profile. If your question fits in one of these subject-specific sub-forums, please ask it there.
Post Reply
avatar
rfj1001
Superstar
Posts: 271
Joined: 14 Dec 2003 18:11
Family Historian: V7
Location: Dorset, England
Contact:

Query - Possible Common Ancestors

Post by rfj1001 » 16 Apr 2020 11:53

I'm getting into the DNA side of genealogy and have DNA matches that suggest, for example, potential 3rd cousins.

I'm trying to build a query in FH that would list the common ancestors for that relationship. It would involve entering the Starting Person and then the cousin relationship (ie 3 in the above example).

I've got to the stage where I can enter the Starting Person and the number of generations back I want to list (which for third cousins is 5 generations back) and the correct list is produced. But how can I enter 3 to get the result I want.

The line I've got currently is

Exclude unless = RelationCode(["Starting Person"]GENS_UP,1) equals ["Generations Required"].

Thanks in advance.

User avatar
Jane
Site Admin
Posts: 8442
Joined: 01 Nov 2002 15:00
Family Historian: V7
Location: Somerset, England
Contact:

Re: Query - Possible Common Ancestors

Post by Jane » 16 Apr 2020 13:07

Code: Select all

=IsTrue(RelationCode(["Individual"],%INDI%,GENS_UP,1) = Calc(Number(["Gens"]) + 2))
is True

P.S Don't forget what Ancestry state as 3rd cousins could well be 2nd or 4th cousins or even further back and double cousins.
Jane
My Family History : My Photography "Knowledge is knowing that a tomato is a fruit. Wisdom is not putting it in a fruit salad."

User avatar
tatewise
Megastar
Posts: 27088
Joined: 25 May 2010 11:00
Family Historian: V7
Location: Torbay, Devon, UK
Contact:

Re: Query - Possible Common Ancestors

Post by tatewise » 16 Apr 2020 13:23

Have you thought of using Tools > How Related instead?
Mike Tate ~ researching the Tate and Scott family history ~ tatewise ancestry

avatar
rfj1001
Superstar
Posts: 271
Joined: 14 Dec 2003 18:11
Family Historian: V7
Location: Dorset, England
Contact:

Re: Query - Possible Common Ancestors

Post by rfj1001 » 16 Apr 2020 15:45

Jane wrote:
16 Apr 2020 13:07

Code: Select all

=IsTrue(RelationCode(["Individual"],%INDI%,GENS_UP,1) = Calc(Number(["Gens"]) + 2))
is True
Thanks Jane, I'm part way there insofar as I can get the correct subset of people (I had to change +2 to +1). But when I run the query there is a window with 3 fields :

Starting Person
Individual
Gens

It is the last 2 that need to be completed for the query to run but I'm not sure where the first is coming from.

The Rows Filter window is just your line of code added as an 'Add if' condition. Is there something else I need to do to stop that first field displaying ?

Thanks in advance

avatar
rfj1001
Superstar
Posts: 271
Joined: 14 Dec 2003 18:11
Family Historian: V7
Location: Dorset, England
Contact:

Re: Query - Possible Common Ancestors

Post by rfj1001 » 16 Apr 2020 15:53

tatewise wrote:
16 Apr 2020 13:23
Have you thought of using Tools > How Related instead?
Thanks MIke for the suggestion.

The problem we have is that the two trees will be owned by different people and all we know is that somehow we are definitely related by DNA. So we have no second person on the same tree to run the How Related query.

Assuming both individual trees are sufficiently complete (and the calculated cousin match is accurate, to take up Jane's point :) ) then the first common identifier to link the two trees should be the surname at the correct ancestor level.

It's a bit rough and ready but working with a list of possible surnames is proving much more easier than visually trying to find the match on, say, someone's online tree.

User avatar
Jane
Site Admin
Posts: 8442
Joined: 01 Nov 2002 15:00
Family Historian: V7
Location: Somerset, England
Contact:

Re: Query - Possible Common Ancestors

Post by Jane » 16 Apr 2020 16:03

Have you requested Starting Person? did you untick the prompt option when you replaced the line?
Jane
My Family History : My Photography "Knowledge is knowing that a tomato is a fruit. Wisdom is not putting it in a fruit salad."

User avatar
tatewise
Megastar
Posts: 27088
Joined: 25 May 2010 11:00
Family Historian: V7
Location: Torbay, Devon, UK
Contact:

Re: Query - Possible Common Ancestors

Post by tatewise » 16 Apr 2020 17:09

["Starting Person"] can appear in any Expression in any tab: General, Columns, Rows.
So you need to check each one and either remove it or change it to ["Individual"].
Mike Tate ~ researching the Tate and Scott family history ~ tatewise ancestry

avatar
rfj1001
Superstar
Posts: 271
Joined: 14 Dec 2003 18:11
Family Historian: V7
Location: Dorset, England
Contact:

Re: Query - Possible Common Ancestors

Post by rfj1001 » 16 Apr 2020 17:21

No prompt - but there were references to Starting Person in some of the expressions defining the columns. (Now just read Mikes post that arrived!) I've deleted those fields and the unwanted field on the opening dialogue box has now gone. The query works almost perfectly. Thanks :)

However, I had to delete one important column and that is the relationship to the individual (eg GGF). I've played around with various expressions but all variants I've tried give an 'expression entered is not recognised as a valid function or some parameters were entered incorrectly'.

Could you give me the correct expression I need to enter please.

Thanks so much

User avatar
tatewise
Megastar
Posts: 27088
Joined: 25 May 2010 11:00
Family Historian: V7
Location: Torbay, Devon, UK
Contact:

Re: Query - Possible Common Ancestors

Post by tatewise » 16 Apr 2020 17:51

I presume that person is the one entered via the Individual prompt.
So try:
=Relationship(["Individual"],,TEXT,1)

It would be helpful if you posted your expression. You can see it, but we can't. So I have had to guess.
Mike Tate ~ researching the Tate and Scott family history ~ tatewise ancestry

avatar
rfj1001
Superstar
Posts: 271
Joined: 14 Dec 2003 18:11
Family Historian: V7
Location: Dorset, England
Contact:

Re: Query - Possible Common Ancestors

Post by rfj1001 » 17 Apr 2020 08:47

Thanks - query now fully working :)

Post Reply