Blog PostLoad Delimited Data into MySQL

How to load Data from a CSV or any delimited file to MySQL:

LOAD DATA LOCAL INFILE '/path/to/file/name' INTO TABLE `tablename` FIELDS TERMINATED BY ',' LINES TERMINATED BY '\n';

Keeping in mind that the delimited used here is , so FIELDS TEMINATED BY ','

You can change the delimiter to any thing your data have.

Comments

Discuss with me and others You need to sign in to post comments