View Full Version : new to mysql
December 21st, 2000, 04:08
how can i make a backup of mysql data and how can i restore it? does each softwre you buy offer a script to back up the
data? i'm looking for basic info
December 21st, 2000, 06:29
Mysqldump does exactely what you are looking for.
mysqldump -u username -ppassword database_name > anything.sql
this will create a file called anything.sql, which you can download with any ftp client. In case you want to insert the info in the database again
mysql -u username -ppass database_name < anything.sql
Note that you have to have access to mysqldump, not all give this.
December 21st, 2000, 07:07
thankyou so much! this is exactly what i'm looking for.
why there is a space between -u and username
but there is no space between -p and password
or is it a typing mistake?
December 22nd, 2000, 11:05
No it has to be like that... something weird... if you don't put a space between -u username it doesn't get the username, and if you put one between the password, it doesn't see it a password...
December 22nd, 2000, 14:25
Just leave off the password.. meaning just give it the -p. It will then prompt you for your password and hide it as you type it.
Powered by vBulletin® Version 4.1.7 Copyright © 2013 vBulletin Solutions, Inc. All rights reserved.