MySQL command line Export Import database, database backup restoreMySQL command line export database:1. Go to the Bin folder in the MySQL directory: cd MySQL to the Bin folder directoryAs I entered the command line: CD C:\Program files\mysql\mysql
You can use the MySQL command line to back up and restore the database. The following describes how to use the MySQL command line to implement this function for your reference.
You can use the MySQL command line to back up and restore the database.
On the MySQL database backup and restore method, here is the first to refer to the Backup tool: Mysqlhotcopy, using the Mysqlhotcopy tool for quick backup, then data restore, using the MySQL command restore, and finally need to export the database
MYSQL command line Import and Export Database details, mysql command line Import and Export
Mysql command line import database:
1. The. SQL file to be imported is moved to the binfile, which is convenient.2. Step 1 of the above-mentioned export3.
MySQL command line Export Database, mysql command line Export
MySQL command line to export the database:1. Go to the bin folder under the MySQL Directory: directory from cd MySQL to the bin folderFor example, if the command line I entered is cd C: \
MySQL command line, you can modify the MySQL database password, the following for you to detail the MySQL command line, if you are interested, may wish to see.
Format: Mysqladmin-u username-P Old password password new password
1, to root add a
Restore a database: mysql-h localhost-u root-p123456 wwwBacking up a database: mysqldump-h localhost-u root-p123456 www > d:\www2008-2-26.sqlWhere www is the database nameThe following is a test in the program$command = "Mysqldump–opt-h $dbhost-u
With the MySQL command line, you can make a backup of the database and restore, the following is a detailed method for you to use the MySQL command line to implement the function of the steps for your reference.MySQL command line export database:1.
MySQL command line export database: 1, go to the Bin folder in the MySQL directory: cd MySQL to the Bin folder directory as I entered the command line: CD C:\Program files\mysql\mysql Server 4.1\bin ( or add the directory directly to the Windows
1. Various usage instructionsA. The simplest usage:[database name[dump file] The above command backs up the specified database to a dump file (dump file), such as:> Test. DumpThe generated Test.dump file contains the Build Table statement (the
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.