MySQL Forums
Forum List  »  InnoDB

Import Multiple CSV Files in Windows
Posted by: Ian Coan
Date: August 31, 2015 12:09PM

I have numerous (over 2000) CSV files all with different names but they all have the same columns of data. I have a table called cc_trans all setup to accept the import of the files. How can I import these all at once? I need it to ignore the first 3 lines of each file. I am using MySQL 5.6.

I tried using the following code in a batch file but mysqlimport wants to create tables based on the filenames of the CSV files. I have a table all created so this won't work.

FOR %%I in (*.csv) DO mysqlimport --local -u root -p[password] [DB_NAME] %%I
PAUSE

Any insight how to do this from command line would be much appreciated. Also a GUI tool if anyone knows of one would be okay as well.

Options: ReplyQuote


Subject
Views
Written By
Posted
Import Multiple CSV Files in Windows
3871
August 31, 2015 12:09PM
1322
August 31, 2015 12:41PM
1506
September 02, 2015 08:19PM
1228
September 04, 2015 11:22AM
2474
September 04, 2015 01:08PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.