Page 1 of 1

problem with importing database into mysql.

Posted: Fri Jan 19, 2007 12:53 am
by sarbas
Hi every body ...
I'm beginner in using LAMPP,

I got the error while try to import a big SQL (184 MB) in to SQLMyAdmin ,
Fatal error: Maximum execution time of 300 seconds exceeded

I try to change the value of memory_limit = 184M and max_execution_time = 0 in Php.ini file and restart the lampp. But still got the problem,

Now using the option of partial import, its consuming more time .

And I try to import the database through terminal window.
while use this command I got error as mysql : command not found

mysql -u "username" root -p "password" < filename.sql

can any one help to overcome this .

Posted: Fri Jan 19, 2007 1:27 am
by Christopher
You could break the 184M file into a number of smaller files and import each separately. Maybe use the split command.

Posted: Fri Jan 19, 2007 1:38 am
by Luke
try this:
mysql -u "username" root -p "databasename" < filename.sql

It should then ask you for your password. Enter it, and let me know how it goes.

error using the mysql command

Posted: Fri Jan 19, 2007 2:11 am
by sarbas
Thanks for your kind reply



I used the above command in terminal window as a root user.

mysql -u "username" root -p "databasename" < filename.sql

but I got the following error

[root@dhcppc0 ~]# mysql -u root -p askpert <askpert.sql
bash: mysql: command not found

My database is in a text file with the extension of .sql . and its a 184 MB, its in my desktop ..........

Posted: Fri Jan 19, 2007 2:19 am
by leewad
The problem should not lie with the size of the file, i have used one bigger than that before and used the following:

Code: Select all

mysql -h localhost  -u username -p databasename < filename.sql

mysql -h localhost -u username -p databasename < filenam

Posted: Fri Jan 19, 2007 2:38 am
by sarbas
Hi

Thank you for your kind reply , I used the below command suggest by you

mysql -h localhost -u username -p databasename < filename.sql

while using the above option I got the following error.

[root@dhcppc0 phpmyadmin]# mysql -h localhost -u root -p askpert1 < askpert.sql
bash: mysql: command not found



Is there any error in my mysql configuration , Actually I'm using LAMPP .
my data base file is in a text file on the desktop. My lampp PhPmyadmin in the folder of
/opt/lampp/phpmyadmin

Please help me with full details .