FYI: mySQL export/import
Posted: Wed 26. May 2004, 21:16
Hi All,
I have just had to export my database from remote server and imported it to my localhost. I was getting an SQL error that meant I could NOT import the database
The reason for the error was that the table 'phpwcms_articlecontent' was just to darn big. mySQL has a 1mb default on it's 'max_allowed_packet' or to us simple folk maximum individual 'query' size. As your site grows (and it will
) you to will have this problem if you should ever need to import a backup of your databes too.
There are a number of fixes if you have control over my.ini but if not a quick hack to your .sql will be equally good...
isolate the table 'phpwcms_articlecontent' then perform a search & replace...
I hope you never have to use it but if you do I hope it helps
I have just had to export my database from remote server and imported it to my localhost. I was getting an SQL error that meant I could NOT import the database
The reason for the error was that the table 'phpwcms_articlecontent' was just to darn big. mySQL has a 1mb default on it's 'max_allowed_packet' or to us simple folk maximum individual 'query' size. As your site grows (and it will
There are a number of fixes if you have control over my.ini but if not a quick hack to your .sql will be equally good...
isolate the table 'phpwcms_articlecontent' then perform a search & replace...
This effectivly breaks your single large query into tiny manageble sizes.Find: ),
Replace with: ); INSERT INTO `phpwcms_articlecontent` VALUES
I hope you never have to use it but if you do I hope it helps