Importing large text files into MYSQL

I am importing a series of text files given to me by the local chamber of commerce.  There are about 30 files.  Some are very small and some are very, very large.  The small ones import with no issue but the very, very large ones are timing out at 650 seconds each time.  Not sure if this is a limit imposed by MYSQL or if there is a way to batch the file so it only processes so many records at one time and can chug through these large files.
pwbigdawgAsked:
Who is Participating?
 
johanntagleConnect With a Mentor Commented:
It looks like you have a wait_timeout setting of 600 seconds.  You can confirm this by doing a "show variables like 'wait_timeout';"

You can change it just for your current session via something like "set wait_timeout=1200;"
0
 
pwbigdawgAuthor Commented:
Exact error is Error code 2013. Lost connection to MySql server during Query.  The duration each time is 600.500 sec.

Query being used is:

LOAD DATA INFILE 'C:\\DIRNAME\\FILENAME.TXT'
    INTO TABLE TABLENAME
      fields terminated BY '\t'
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.