Hi Jutta
I patched your ged data to make it validate, and wrote a little script
to get you going. See:
o https://savage.net.au/misc/jutta.ged
o https://savage.net.au/misc/jutta.log
o https://savage.net.au/misc/jutta.sample (Rename to jutta.pl)
My web hosting company will not let me upload files with names like:
o jutta.pl
o jutta.pl.txt
On 09/06/17 05:55, Jutta Wrage wrote:
Hi!
Am 07.05.2017 um 02:56 schrieb Ron Savage:
I have this code snippet included for testing purposes now:
my $surname;
if(my $husband = $i->husband()) {
$surname = $husband->get_value(["name", 1], "surn");
} else {
$surname = "";
}
I get a surname now for married people there. But if there are more than one
partners it is always the very first one taken there, it seems, even if a loose
partnership without marriage.
I suspect the reason you get 1 is that you have my $husband in scalar context.
Try storing the return value in an array and see if you get the others.
I still do not get anything useful working.
For now I am near to parse the gedcom file myself to get what I want for my
table.
What I really want is:
(a) either get all surnames of a person
(b) or get all parnter names
(c) or get all names of married partners (wich is the same als the Family names
in (a) - if my entries have been made correctly
Here an example of an individual:
0 @I48949664@ INDI
1 NAME Anna Margareta/Hüttmann/
2 GIVN Anna Margareta
2 SURN Hüttmann
1 SEX F
1 NAME Anna Margaretha/Hüttmann/
2 TYPE 6
2 GIVN Anna Margaretha
2 SURN Hüttmann
1 NAME /Wrage/
2 TYPE 3
2 SURN Wrage
1 NAME /Kruse/
2 TYPE 3
2 SURN Kruse
She has been married first to Wrage and got that Name until second marriage
with Kruse.
Her name when she died was in short:
Anna Margareta Kruse, geb. (born) Hüttmann
long:
Anna Margareta Kruse, geb. Hüttmann, gesch. (divorced) Wrage.
Whatever I do can be a workaround only:
- Sometimes I may forget to add the new mariage name instead of adding it.
- MacStammbaum (MacFamilytree now I guess) produces a Gedcom file where each
Family has a husband. It does not have families with a man just being father of
a so called child.
In the table I will mark things like "have birth record church/administration" "have
marriage record 1 2 3" and so on.
Maybe I will move the marriage record overview to a second tage just with all
families but for now I need the marriage names added anyway.
Regards,
Jutta
--
http://www.witch.westfalen.de
--
Ron Savage - savage.net.au