1. Prepare the excel table we need to import, which contains a lot of data that we need to import.
2. Modify the table header to English and try to correspond to the database table fields
3. Convert excel to CSV data format
(1) Click Save As
(2) Select the file type as: CSV (comma separated) (*.csv), click Save (then continue to click Yes in the pop-up box)
(3) The conversion is successful and you get something like this
Here I am using Navicat, others are also possible, such as SQLyog, but the click place is different
1. Create a database, and then create a table to receive excel data (this step is relatively Simple, no screenshots required)
2. Select the table to import data, right-click, and click Import Wizard
3. Select the CSV file and click Next
4. Select the CSV file just generated and click Next
5. Click Next
6. According to Fill in your own requirements and click Next
7. Select the table to import data and click Next
8. Fill in the corresponding field name, and then click Next
9. Click Next step
10. Click the start button again to start importing
##Import successful:
The above is the detailed content of How to batch import Excel data into MySQL. For more information, please follow other related articles on the PHP Chinese website!