Reputation: 371
I am having a huge file of comma separated values (CSV) that I need to import into a mysql database..
The file size is 7 GB, and the memory size on my machine is 4.00 GB..
I tried to load it using "LOAD DATA LOCAL INFILE" SQL Command, but it has been more than 12 hours and it is still running !
The ideas that I think might should be done is to either :
Do you think there might be a better and more efficient approach to import such huge file into the MySQL ?
Upvotes: 2
Views: 5043
Reputation: 46892
[So you can mark the Q as closed - and I get some points!]
Dropping the index should help.
(Although I am surprised it helped so much. I guess MySQL couldn't keep the whole index in memory, which seems odd, as it should be smaller than the data.)
Upvotes: 1