MySQL mysqlimport Basic usage

Help us to keep this website almost Ad Free! It takes only 10 seconds of your time:
> Step 1: Go view our video on YouTube: EF Core Bulk Insert
> Step 2: And Like the video. BONUS: You can also share it!

Example

Given the tab-separated file employee.txt

1 \t Arthur Dent
2 \t Marvin
3 \t Zaphod Beeblebrox

$ mysql --user=user --password=password mycompany -e 'CREATE TABLE employee(id INT, name VARCHAR(100), PRIMARY KEY (id))'

$ mysqlimport --user=user --password=password mycompany employee.txt


Got any MySQL Question?