June 2016
Beginner
456 pages
9h 31m
English
In this recipe, we will learn how to import and export bulk data with MySQL. Many times it happens that we receive data in CSV or XML format and we need to add this data to the database server for further processing. You can always use tools such as MySQL workbench and phpMyAdmin, but MySQL provides command-line tools for the bulk processing of data that are more efficient and flexible.
Follow these steps to import and export bulk data:
$ mysqldump -u admin -p mytestdb > db_backup.sql
$ mysqldump -u admin -p mytestdb table1 table2 > table_backup.sql
Read now
Unlock full access