1
tedsmith
MySQL Restore Works but No Data in Tables
  • 2005/12/23 17:48

  • tedsmith

  • Home away from home

  • Posts: 1151

  • Since: 2004/6/2 1


Hi

I'm trying to recreate a copy of my Intranet site at work (which runs on Xoops) locally at home. I've got a backup of the database using phpMyAdmin and all the XOOPS files.

I've installed XAMPP and got all that up and running a treat. No problems there.

However, when I try to restore my database using phpMyAdmin I get an error where it states that the syntax is wrong.
#1064 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'CREATE TABLE IF NOT EXISTS 'xoops_avatar' (
'avatar_id' mediumint(8)' unsing at line 1


So I tried installing MySQL Administrator instead and used it's restore feature (which is great by the way). I have tried it using both Latin1, Latin5 and UTF-8 as the encoding method. Using every one it reads the entire backup (it takes a couple of minutes to do in fact) and then says that the restore was successfull. Bu when I go and examine the database, all the tables are there, but empty. They all say 0 bytes for the 'Data Lenght' and the 'Index Length' all say 1Kb. No data in em!

No, I'm guessing that the problem here is that the database at work uses MySQL 4.0.x (can't remeber exactly which version, but it's about 8 months old) and XAMPP uses the MySQL 5 I think. But I though MySQL Administrator could deal with both 4 and 5 database backups.

Does anyone know what the problem could be and how to fix?

Thanks

Ted

2
jdseymour
Re: MySQL Restore Works but No Data in Tables

What was the original database version, and what version are you importing to?

3
tedsmith
Re: MySQL Restore Works but No Data in Tables
  • 2005/12/23 18:19

  • tedsmith

  • Home away from home

  • Posts: 1151

  • Since: 2004/6/2 1


The backup version is MySQL Server 4.1.11 using phpMyAdmin 2.6.0 and PHP ver 4.3.7.

The restoration is using MySQL Server 5.0.15 (that came shipped with XAMPP) and MySQL Administrator 1.0.21 having just downgraded it from 1.1 to try and resolve above issue, but made no difference.

Therefore, as stated, I suspect it's a version issue but I'm not sure how to fix it.

Does this help JD?

Ted

4
jdseymour
Re: MySQL Restore Works but No Data in Tables

Not sure, Google for the MySQL --compatible command from your version to the new version, see if you find any hits on it.

Sorry not feeling well at the moment or would check for you.

5
tedsmith
Re: MySQL Restore Works but No Data in Tables
  • 2005/12/23 19:51

  • tedsmith

  • Home away from home

  • Posts: 1151

  • Since: 2004/6/2 1


Had to resort to uninstalling version 5that came with XAMPP and downloaded and installed version 4.1.1. from mysql.com. Spent another hour or so trying to work out how to remove the old version 5 MySQL service in order that the version 4 service could start . click here if you are having same problem).

Eventually got that working, and got MySQL Administrator and MySQL Server 4.1.1. to play with each other.

The restoration of the version 4 backup was still unsuccessfull. I don't get it. Giving up for now

Ted

Login

Who's Online

324 user(s) are online (255 user(s) are browsing Support Forums)


Members: 0


Guests: 324


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Nov 30
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits