Page 1 of 1

using mysql from command line?

PostPosted: 02. July 2009 19:30
by steve02476
xampp is working beautifully on my XP system. I can access mysql via phpmyadmin very well.

However, some things I am accustomed to doing with mysql directly - like importing large data sets (50MB). I think using PHP limits how much I can import via phpmyadmin.

Is there some way I can access the mysql inside xampp from the XP cmd command line?

Or is there another good way to import a 50MB sql dump into mysql?

Thanks for the help!

Re: using mysql from command line?

PostPosted: 02. July 2009 19:45
by steve02476
I'm a moron... :oops:

Here's the answer, I think:

go into the XP command window, and type:

Code: Select all
F:\>\xampp\mysql\bin\mysql -u root


(of course, change the path for wherever your xampp directory is...)

Hope this helps someone else. -Steve

ADDITION: after you do the above, to do the actual data import:
Code: Select all
mysql> use databasename;
mysql> source C:\\Documents and Settings\\yourname\\My Documents\\yourdumpfile.sql;

Re: using mysql from command line?

PostPosted: 02. July 2009 20:03
by Teratornis
If you are used to using Unix/Linux/GNU command-line tools, you might like to install Cygwin.

Re: using mysql from command line?

PostPosted: 02. July 2009 21:02
by steve02476
Thanks, that's a good idea.