Question [SOLVED] webtrees 2.0.0-alpha.5: Placename Import Broken
- dbq-andersons
- Topic Author
- Offline
- New Member
Less
More
5 years 2 weeks ago - 5 years 2 weeks ago #1
by dbq-andersons
Bill Anderson | Onalaska, WI | genealogy.dbq-andersons.com
webtrees 2.1.16 | Apache 2.4.52-1 | PHP 8.1.2-1 | MySQL 8.0.32-0
Ubuntu 22.04.1 LTS Running on a PC in My Basement
webtrees 2.0.0-alpha.5: Placename Import Broken was created by dbq-andersons
Hi Everyone,
Since I upgraded my private test site from 2.0.0-alpha.4 to 2.0.0-alpha.5, my GEDCOM import reports that the first placename in the GEDCOM is an invalid GEDCOM record.
Error I receive when importing GEDCOM:
Raw GEDCOM for that place:
Did something in this mechanism change? If so, what format in the GEDCOM is now needed to import placenames?
Thanks,
Bill
Since I upgraded my private test site from 2.0.0-alpha.4 to 2.0.0-alpha.5, my GEDCOM import reports that the first placename in the GEDCOM is an invalid GEDCOM record.
Error I receive when importing GEDCOM:
Code:
Invalid GEDCOM record
0 _PLAC Afton, Sedgwick, Kansas, United States
1 MAP
2 LATI N37.6027806
2 LONG W97.6316694
0 _PLAC Afton, Sedgwick, Kansas, United States
1 MAP
2 LATI N37.6027806
2 LONG W97.6316694
Raw GEDCOM for that place:
Code:
0 _PLAC Afton, Sedgwick, Kansas, United States
1 MAP
2 LATI N37.6027806
2 LONG W97.6316694
Did something in this mechanism change? If so, what format in the GEDCOM is now needed to import placenames?
Thanks,
Bill
Bill Anderson | Onalaska, WI | genealogy.dbq-andersons.com
webtrees 2.1.16 | Apache 2.4.52-1 | PHP 8.1.2-1 | MySQL 8.0.32-0
Ubuntu 22.04.1 LTS Running on a PC in My Basement
Last edit: 5 years 2 weeks ago by dbq-andersons.
Please Log in or Create an account to join the conversation.
- fisharebest
- Offline
- Administrator
5 years 2 weeks ago #2
by fisharebest
Greg Roach - greg@subaqua.co.uk - @fisharebest@phpc.social - fisharebest.webtrees.net
Replied by fisharebest on topic webtrees 2.0.0-alpha.5: Placename Import Broken
The import logic is expecting an XREF.
e.g. something like
e.g. something like
Code:
0 @P123@ _PLAC
Greg Roach - greg@subaqua.co.uk - @fisharebest@phpc.social - fisharebest.webtrees.net
Please Log in or Create an account to join the conversation.
- dbq-andersons
- Topic Author
- Offline
- New Member
5 years 2 weeks ago #3
by dbq-andersons
Bill Anderson | Onalaska, WI | genealogy.dbq-andersons.com
webtrees 2.1.16 | Apache 2.4.52-1 | PHP 8.1.2-1 | MySQL 8.0.32-0
Ubuntu 22.04.1 LTS Running on a PC in My Basement
Replied by dbq-andersons on topic webtrees 2.0.0-alpha.5: Placename Import Broken
Thanks Greg for the reply.
Since RootsMagic GEDCOM export does not include an XREF with the placenames (*sigh*), looks like I'll have to tweak my rootsmagic -> webtrees GEDCOM conversion script (already does some tag removal and image path wrangling) to include adding those in.
Thanks again,
Bill
Since RootsMagic GEDCOM export does not include an XREF with the placenames (*sigh*), looks like I'll have to tweak my rootsmagic -> webtrees GEDCOM conversion script (already does some tag removal and image path wrangling) to include adding those in.
Thanks again,
Bill
Bill Anderson | Onalaska, WI | genealogy.dbq-andersons.com
webtrees 2.1.16 | Apache 2.4.52-1 | PHP 8.1.2-1 | MySQL 8.0.32-0
Ubuntu 22.04.1 LTS Running on a PC in My Basement
Please Log in or Create an account to join the conversation.
- fisharebest
- Offline
- Administrator
5 years 2 weeks ago #4
by fisharebest
Greg Roach - greg@subaqua.co.uk - @fisharebest@phpc.social - fisharebest.webtrees.net
Replied by fisharebest on topic webtrees 2.0.0-alpha.5: Placename Import Broken
I think the previous version of webtrees would have created a dummy XREF to match the type (_PLAC), and each place would have overwritten the previous one in the database.
So you'd have been left with just the final place record - which would have been ignored.
So you'd have been left with just the final place record - which would have been ignored.
Greg Roach - greg@subaqua.co.uk - @fisharebest@phpc.social - fisharebest.webtrees.net
Please Log in or Create an account to join the conversation.
- ric2015
- Offline
- Senior Member
5 years 2 weeks ago #5
by ric2015
While you're at it, you could convert these _PLAC-Records to _LOC-Records . This type of record isn't supported by webtrees directly either (not standard GEDCOM), but by my "Shared Places" module - You'd be able to use the location data in webtrees then (if you don't already have it on the places themselves anyway). You'd have to convert
to
Otherwise, as pointed out by Greg, webtrees doesn't do anything with _PLAC-records, so you can also just drop them completely in your script (if you don't want to re-export from webtrees).
Richard
webtrees 2.1.17 at cissee.de/webtrees2
Vesta custom modules (Classic Look & Feel, Gov4webtrees, Shared Places, Extended Relationships) available at cissee.de
Replied by ric2015 on topic webtrees 2.0.0-alpha.5: Placename Import Broken
dbq-andersons wrote: looks like I'll have to tweak my rootsmagic -> webtrees GEDCOM conversion script
While you're at it, you could convert these _PLAC-Records to _LOC-Records . This type of record isn't supported by webtrees directly either (not standard GEDCOM), but by my "Shared Places" module - You'd be able to use the location data in webtrees then (if you don't already have it on the places themselves anyway). You'd have to convert
Code:
0 _PLAC Afton, Sedgwick, Kansas, United States
1 MAP
2 LATI N37.6027806
2 LONG W97.6316694
to
Code:
0 @L123@ _LOC
1 NAME Afton, Sedgwick, Kansas, United States
1 MAP
2 LATI N37.6027806
2 LONG W97.6316694
Otherwise, as pointed out by Greg, webtrees doesn't do anything with _PLAC-records, so you can also just drop them completely in your script (if you don't want to re-export from webtrees).
Richard
webtrees 2.1.17 at cissee.de/webtrees2
Vesta custom modules (Classic Look & Feel, Gov4webtrees, Shared Places, Extended Relationships) available at cissee.de
Please Log in or Create an account to join the conversation.
- dbq-andersons
- Topic Author
- Offline
- New Member
5 years 2 weeks ago #6
by dbq-andersons
Bill Anderson | Onalaska, WI | genealogy.dbq-andersons.com
webtrees 2.1.16 | Apache 2.4.52-1 | PHP 8.1.2-1 | MySQL 8.0.32-0
Ubuntu 22.04.1 LTS Running on a PC in My Basement
Replied by dbq-andersons on topic webtrees 2.0.0-alpha.5: Placename Import Broken
Thanks for the tip Richard. I'll keep that in mind as I change things around.
Cheers!
Bill
Cheers!
Bill
Bill Anderson | Onalaska, WI | genealogy.dbq-andersons.com
webtrees 2.1.16 | Apache 2.4.52-1 | PHP 8.1.2-1 | MySQL 8.0.32-0
Ubuntu 22.04.1 LTS Running on a PC in My Basement
Please Log in or Create an account to join the conversation.
- dbq-andersons
- Topic Author
- Offline
- New Member
5 years 2 weeks ago #7
by dbq-andersons
Bill Anderson | Onalaska, WI | genealogy.dbq-andersons.com
webtrees 2.1.16 | Apache 2.4.52-1 | PHP 8.1.2-1 | MySQL 8.0.32-0
Ubuntu 22.04.1 LTS Running on a PC in My Basement
Replied by dbq-andersons on topic webtrees 2.0.0-alpha.5: Placename Import Broken
So, I took my own ideas and Greg's and Richard's..thought about them...and went completely somewhere else. Seems to be how my script writing works more often than not.
I wrote a script on my server late last year that harvests the data pertaining to all of the places in a RootsMagic-exported GEDCOM and dumps the data into a WebTrees-importable file ($LEVEL;$COUNTRY;$STATE;$COUNTY;$TOWN;$LONG;$LAT;$ZOOM;). I added a few lines to that script that lop off the last two sections of the GEDCOM (_PLAC and _EVDEF) once the placename file is built. Import is working much better with the truncated GEDCOM.
Thank Greg and Richard for the thoughts and explanations.
Bill
I wrote a script on my server late last year that harvests the data pertaining to all of the places in a RootsMagic-exported GEDCOM and dumps the data into a WebTrees-importable file ($LEVEL;$COUNTRY;$STATE;$COUNTY;$TOWN;$LONG;$LAT;$ZOOM;). I added a few lines to that script that lop off the last two sections of the GEDCOM (_PLAC and _EVDEF) once the placename file is built. Import is working much better with the truncated GEDCOM.
Thank Greg and Richard for the thoughts and explanations.
Bill
Bill Anderson | Onalaska, WI | genealogy.dbq-andersons.com
webtrees 2.1.16 | Apache 2.4.52-1 | PHP 8.1.2-1 | MySQL 8.0.32-0
Ubuntu 22.04.1 LTS Running on a PC in My Basement
Please Log in or Create an account to join the conversation.