MySQL Forums
Forum List  »  Newbie

CSV Bulk Insert
Posted by: Adam Nottingham
Date: April 01, 2010 10:19AM

I am trying to bulk insert a csv file named testFile into a table named csvTest. However, I keep getting the error:

ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that
corresponds to your MySQL server version for the right syntax to use near 'BULK

What is the correct syntax for this?

By the way I am using MySQL server 5.1

The code I am using:
BULK
INSERT csvTest
FROM 'c:\testFile.txt'
WITH
(
FIELDTERMINATOR = ',',
ROWTERMINATOR = '\n'
);

thanks.

Options: ReplyQuote


Subject
Written By
Posted
CSV Bulk Insert
April 01, 2010 10:19AM
April 01, 2010 10:23AM
April 01, 2010 10:36AM
April 01, 2010 11:12AM
April 01, 2010 11:45AM
April 01, 2010 12:32PM


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.