For issues related to the current stable release please use it's own Help forum.
IMPORTANT:Please read this before using an git or nightly build version: wiki.webtrees.net/en/GIT

Before asking for help please read "How to request help" by clicking on that tab above here.

TOPIC: [SOLVED] webtrees 2.0.0-alpha.5: Placename Import Broken

webtrees 2.0.0-alpha.5: Placename Import Broken 1 week 2 days ago #1

  • dbq-andersons
  • dbq-andersons's Avatar
  • Offline
  • New
  • Posts: 39
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:
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:
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 1.7.12 | NGINX 1.14.0 | PHP 7.2.13-1 | MySQL 5.7.25
Ubuntu 16.04 LTS Running on a PC in My Basement
Last Edit: 1 week 2 days ago by dbq-andersons.
The administrator has disabled public write access.

webtrees 2.0.0-alpha.5: Placename Import Broken 1 week 2 days ago #2

  • fisharebest
  • fisharebest's Avatar
  • Offline
  • Administrator
  • Posts: 10825
The import logic is expecting an XREF.

e.g. something like
0 @P123@ _PLAC
Greg Roach - This email address is being protected from spambots. You need JavaScript enabled to view it. - fisharebest.webtrees.net
The administrator has disabled public write access.

webtrees 2.0.0-alpha.5: Placename Import Broken 1 week 2 days ago #3

  • dbq-andersons
  • dbq-andersons's Avatar
  • Offline
  • New
  • Posts: 39
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
Bill Anderson | Onalaska, WI | genealogy.dbq-andersons.com
Webtrees 1.7.12 | NGINX 1.14.0 | PHP 7.2.13-1 | MySQL 5.7.25
Ubuntu 16.04 LTS Running on a PC in My Basement
The administrator has disabled public write access.

webtrees 2.0.0-alpha.5: Placename Import Broken 1 week 2 days ago #4

  • fisharebest
  • fisharebest's Avatar
  • Offline
  • Administrator
  • Posts: 10825
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.
Greg Roach - This email address is being protected from spambots. You need JavaScript enabled to view it. - fisharebest.webtrees.net
The administrator has disabled public write access.

webtrees 2.0.0-alpha.5: Placename Import Broken 1 week 1 day ago #5

  • ric2015
  • ric2015's Avatar
  • Offline
  • New
  • Posts: 86
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

0 _PLAC Afton, Sedgwick, Kansas, United States
1 MAP
2 LATI N37.6027806
2 LONG W97.6316694

to

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 1.7.10 at cissee.de/webtrees
Custom modules for 1.7.9.x and 2.x (Extended Relationships, Gov4Webtrees, Shared Places) available at cissee.de
The administrator has disabled public write access.

webtrees 2.0.0-alpha.5: Placename Import Broken 1 week 1 day ago #6

  • dbq-andersons
  • dbq-andersons's Avatar
  • Offline
  • New
  • Posts: 39
Thanks for the tip Richard. I'll keep that in mind as I change things around.

Cheers!

Bill
Bill Anderson | Onalaska, WI | genealogy.dbq-andersons.com
Webtrees 1.7.12 | NGINX 1.14.0 | PHP 7.2.13-1 | MySQL 5.7.25
Ubuntu 16.04 LTS Running on a PC in My Basement
The administrator has disabled public write access.

webtrees 2.0.0-alpha.5: Placename Import Broken 1 week 23 hours ago #7

  • dbq-andersons
  • dbq-andersons's Avatar
  • Offline
  • New
  • Posts: 39
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
Bill Anderson | Onalaska, WI | genealogy.dbq-andersons.com
Webtrees 1.7.12 | NGINX 1.14.0 | PHP 7.2.13-1 | MySQL 5.7.25
Ubuntu 16.04 LTS Running on a PC in My Basement
The administrator has disabled public write access.
Powered by Kunena Forum