If you need to upgrade your PGV installation, then hopefully you will also consider that you can conveniently move to webtrees with our PGV-to-webtrees wizard. It will move ALL your users, news, favorites and family trees to webtrees in a matter of minutes.

TOPIC: [SOLVED] Error while importing from PGV 4.2.4

Error while importing from PGV 4.2.4 1 year 10 months ago #1

  • robi
  • robi's Avatar
  • Offline
  • New
  • Posts: 3
Hello.

I run this wonderful software since many many years and now I'm trying to migrate to webtrees.
PGV site: www.nunnisoft.ch/genealogia/

Output and error I get during import into webtrees:

PhpGedView to webtrees transfer wizard
/var/www/phpGedView/index/config.php => wt_site_setting…
pgv_site_setting => wt_site_setting…
pgv_gedcom => wt_gedcom…
pgv_gedcom_setting => wt_gedcom_setting…
pgv_user => wt_user…
pgv_user_setting => wt_user_setting…
pgv_user_gedcom_setting => wt_user_gedcom_setting…
Reading configuration file /var/www/phpGedView/index/Nunnari.ged_conf.php
Reading privacy file /var/www/phpGedView/index/Nunnari.ged_priv.php
pgv_hit_counter => wt_hit_counter…
pgv_site_setting => wt_module_setting…
pgv_favorites => wt_favorite…
pgv_news => wt_news…
pgv_nextid => wt_next_id…
pgv_messages => wt_message…
/var/www/webtrees/app/Statement.php:82 SQLSTATE[HY000]: General error: 1411 Incorrect datetime value: 'Sep 20 2007 12:57:05' for function str_to_date #0 /app/Statement.php:82 PDOException("SQLSTATE[HY000]: General error: 1411 Incorrect datetime value: 'Sep 20 2007 12:57:05' for function str_to_date") #1 /admin_pgv_to_wt.php:1094 execute()

Can anybody help?
Thank you and best regards.
Roberto
The administrator has disabled public write access.

Error while importing from PGV 4.2.4 1 year 10 months ago #2

  • fisharebest
  • fisharebest's Avatar
  • Offline
  • Administrator
  • Posts: 11117
Your "pgv_messages" table contains timestamps that aren't in the expected format.

Can you look in this table (e.g. using phpMyAdmin) and tell us which format (or formats) are being used.

webtrees is expecting PGV to use "%a, %d %M %Y %H:%i:%s".

For an explanation of the "%Y" placeholders, see dev.mysql.com/doc/refman/5.7/en/date-and...function_date-format
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.

Error while importing from PGV 4.2.4 1 year 10 months ago #3

  • bertkoor
  • bertkoor's Avatar
  • Offline
  • Gold
  • Greetings from Utrecht, Holland
  • Posts: 1575
The function it executes is
STR_TO_DATE(m_created, '%a, %d %M %Y %H:%i:%s')

So it expects a date in the format "Abbreviated weekday name (Sun..Sat) comma day monthname year hour colon minute colon second"
But the actual date is in another format: "Monthname day year hour colon minute colon second"

It's worth a shot to try to adjust the expected format.
In the file admin_pgv_to_wt.php (in the root of your webtrees folder) adjust line 1091.
Replace the sequence '%a, %d %M %Y %H:%i:%s' at the end of the line with '%M %d %Y %H:%i:%s'
(no day of the week, month comes first)

I cannot guarantee you don't get simular errors elsewhere in the conversion. Maybe the main developer Greg has a better insight in the cause and a better way to fix it.

(edit: I see Greg cross-posted another proposal, so never mind...)
stamboom.BertKoor.nl runs on webtrees v1.7.9
Last Edit: 1 year 10 months ago by bertkoor.
The administrator has disabled public write access.

Error while importing from PGV 4.2.4 1 year 10 months ago #4

  • robi
  • robi's Avatar
  • Offline
  • New
  • Posts: 3
Hello.

Thank you Greg and thank you Bertkoor for you helpful hints.
The problem was in fact in the old db, in table messages.. most records were in the correct format, but some was wrong and some missing at all. Once I corrected all of them, rerun the import and it run smooth till the end. :-)
Now I have to bring in all the media that was not imported..

Best regards.
Roberto
The administrator has disabled public write access.

[SOLVED] Error while importing from PGV 4.2.4 1 year 10 months ago #5

  • robi
  • robi's Avatar
  • Offline
  • New
  • Posts: 3
Problem solved.
The administrator has disabled public write access.

Error while importing from PGV 4.2.4 1 year 10 months ago #6

  • robi
  • robi's Avatar
  • Offline
  • New
  • Posts: 3
phpgedview now offline and webtrees is taking care of my genealogy.
Thank you all for this wonderful software!! :-)
The administrator has disabled public write access.
Powered by Kunena Forum