mysql/phpmyadmin import problems *newbie*

Problems with the Windows version of XAMPP, questions, comments, and anything related.

mysql/phpmyadmin import problems *newbie*

Postby roper1979 » 26. April 2009 23:36

I'm currently tring to import a database - I'm running on a 'test rig' so all my sql/php is running on localhost.
The database is around 255mb.
I've edited php.ini so memory_limit, post_max_size & upload_max_filesize to 512.
The dump is no extended inserts.
I retrieve two tables, but then I get the error message "Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 255567249 bytes) in C:\xampp\phpMyAdmin\libraries\import.lib.php on line 269"
The offending line reads "$GLOBALS['import_text'] = substr($GLOBALS['import_text'], $size)"
$size is determined by $_Globals 'read_limit', and I can't find what determines the read limit.

What am I doing wrong?
roper1979
 
Posts: 5
Joined: 21. April 2009 20:27

Re: mysql/phpmyadmin import problems *newbie*

Postby Sharley » 26. April 2009 23:46

roper1979 wrote:I'm currently tring to import a database
How exactly are you doing this import?

roper1979 wrote:I've edited php.ini
Which php.ini file did you edit?
What version of XAMPP and OS please?
User avatar
Sharley
AF Moderator
 
Posts: 3316
Joined: 03. October 2008 05:10
Location: Yeppoon, Australia Time Zone: GMT/UTC+10
Operating System: Win 7 Pro 32bit/XP Pro SP3

Re: mysql/phpmyadmin import problems *newbie*

Postby roper1979 » 26. April 2009 23:54

I'm importing the database by using phpmyadmin to create the db, then selecting the db and using the import option on the right hand pane.
Partial import is left checked.

php.ini located in the \php folder.

OS is 32-bit XP with SP3, and I'm using xampp 1.7.1
roper1979
 
Posts: 5
Joined: 21. April 2009 20:27

Re: mysql/phpmyadmin import problems *newbie*

Postby Sharley » 27. April 2009 00:25

I take it you downloaded a big dump to your HD and are trying to import this dump into your new database created using phpMyAdmin.

From memory there is a size limit on the import sql file at around 65 megs.

You may have to split the file into smaller import chunks to import a 255 meg sql file.

Search Google as I believe there is an app that will perhaps allow importing large databases, again from memory - Try BigDump.
http://www.ozerov.de/bigdump.php
User avatar
Sharley
AF Moderator
 
Posts: 3316
Joined: 03. October 2008 05:10
Location: Yeppoon, Australia Time Zone: GMT/UTC+10
Operating System: Win 7 Pro 32bit/XP Pro SP3

Re: mysql/phpmyadmin import problems *newbie*

Postby roper1979 » 27. April 2009 00:57

I'm trying big dump, but it now appears that other stuff is going wrong... ;)
Big dump comes back with...
"Error at the line 3001: tAgents` VALUES (3011296,11,1000014,60001573,1,-18,2);

Query: tAgents` VALUES (3011296,11,1000014,60001573,1,-18,2);

MySQL: 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 'tAgents` VALUES (3011296,11,1000014,60001573,1,-18,2)' at line 1"

what does 'near' mean?
roper1979
 
Posts: 5
Joined: 21. April 2009 20:27

Re: mysql/phpmyadmin import problems *newbie*

Postby Sharley » 27. April 2009 01:09

IMHO, when you create the dump you have to select the compatibility mode and again when you are importing.

http://dev.mysql.com/doc/refman/5.1/en/ ... -mode.html

Click on the little question marks in phpMyAdmin for the help docs.

Near means near line 1 but does not mean line 1.

Things to keep in mind are the versions of MySQL may be different from the dump to the import and this may give syntax errors in the sql file until this difference is corrected by editing the sql file or by the compatibly mode perhaps.
User avatar
Sharley
AF Moderator
 
Posts: 3316
Joined: 03. October 2008 05:10
Location: Yeppoon, Australia Time Zone: GMT/UTC+10
Operating System: Win 7 Pro 32bit/XP Pro SP3


Return to XAMPP for Windows

Who is online

Users browsing this forum: No registered users and 51 guests