Tuesday, 20 August 2013

Import CSV to MySQL

mysql> load data local infile 'c:\\mysql\\IPCOUNTRY.CSV'
    -> INTO TABLE IPCountryLoc_old
    -> fields TERMINATED BY ','
    -> OPTIONALLY ENCLOSED BY '"'
    -> ESCAPED BY '\\'
    -> LINES TERMINATED BY '\r\n';
Query OK, 8889310 rows affected (2 min 5.59 sec)
Records: 8889310  Deleted: 0  Skipped: 0  Warnings: 0

No comments:

Post a Comment