Database Restore Error

This is an archive of the phpBB 2.0.x support forum. Support for phpBB2 has now ended.
Forum rules
Following phpBB2's EoL, this forum is now archived for reference purposes only.
Please see the following announcement for more information: viewtopic.php?f=14&t=1385785
Locked
mklenner
Registered User
Posts: 1
Joined: Tue Dec 23, 2008 4:11 am

Database Restore Error

Post by mklenner »

Your board's URL: http://jnestlerode.ipower.com/phpBB/index.php
Version of phpBB2: 2.0.20
Was this a fresh install or a(n) update/upgrade/conversion (please be specific)? Host Migration
Did you use an automated wizard provided by your host to install phpBB? No
MODs you have installed: None
When the problem started: Restore of Database
Your level of expertise (be honest): Intermediate
Template(s) used: Subsilver
Language(s) used: English
Version of PHP used: 4.4.7
Database and version used: mySQL 5.045

Okay... I've been asked to help someone migrate to a new host, and I installed phpBB 2.0.20 for parity. I will upgrade to phpBB3 at some point soon, but the old hose will be going dark soon, and I need to get things sorted out. I used the Backup Database on the old system, installed phpBB2 on the new one, and tried to do a restore. I get the following error:

Code: Select all

Error importing backup file

DEBUG MODE

SQL Error : 1062 Duplicate entry 'charts' for key 1

INSERT INTO phpbb_search_wordlist (word_text, word_id, word_common) VALUES('charts', '3785', '0')

Line : 980
File : admin_db_utilities.php
I've been through the archives and found no answers. The auto increments appear to be fine.

Suggestions?
User avatar
ric323
Former Team Member
Posts: 22910
Joined: Tue Feb 06, 2007 12:33 am
Location: Melbourne, Australia
Name: Ric
Contact:

Re: Database Restore Error

Post by ric323 »

Probably you have a different "collation" setting on the old and new databases, so accented characters are getting converted to the unaccented equivalent, making some of the words in the search tables appear the same.

The easiest solution is to delete all the search tables from the backup file (using a text editor which can handle large files). These make up about 50% of the data in the file, and are the three tables which have "search_" in their name.
(phpbb_search_results, phpbb_search_wordlist, and phpbb_search_wordmatch)

If you are going to go straight to phpBB3 without making the database live, then don't worry about the search tables.
If you want to go live with the phpBB2 board, then you would need to rebuild the seac index using this MOD
http://www.phpbb.com/community/viewtopic.php?t=329629
The Knowledge Base contains solutions to many common problems!
How to fix "Doesn't have a default value" and "Incorrect string value: xxx for column 'post_text' " errors.
How to do a clean re-install of the latest phpBB3 version.
Problems with permissions? Read phpBB3 Permissions
Locked

Return to “2.0.x Support Forum”