MySQL database data backup and recovery

Source: Internet
Author: User

Backup data:

C:\users\administrator>mysqldump-uroot--password-v test01 test02 >e:\temp\20170507  ****-- connecting to localhost ...  for table test02 ... -- sending SELECT query ... -- Retrieving rows ... --disconnecting from localhost ...
Mysql>Use test01;database changedmysql>Select* FROM test02 to outfile'E:\temp\20170507\a5.sql'- ; ERROR1(HY000): Can't create/write to file'E:emp20170507a5.sql'(Errcode:2-No suchfileor directory) MySQL>Select* FROM test02 to outfile'E:/temp/20170507/a5.sql'; Query OK,8Rows Affected (0.00Sec

Recover data:

Using the Load Data method

' E:/temp/20170507/a5.sql '  8 rows affected (0.038  0  0  0 

Using the Mysqlimport method

C:\users\administrator>mysqlimport--user root--password-v test01 e:/temp/0507/*  file: e:/temp/20170507/8  0   0  0 disconnecting from localhost

MySQL database data backup and recovery

Contact Us

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.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.