I have a mysql database with a single table, that includes an autoincrement ID, a string and two numbers. I want to populate this database with many strings, coming from a text file, with all numbers initially reset to 0.

Is there a way to do it quickly? I thought of creating a script that generates many INSERT statements, but that seems somewhat primitive and slow. Especially since mysql is on remote site.

thanks! when I try to do that, I get: LOAD DATA INFILE 'bundles/PACKAGE1.TXT' INTO TABLE textrating FIELDS TERMINATED BY '\t' LINES TERMINATED BY '\n' IGNORE 0 LINES (textline); ERROR 1045 (28000): Access denied for user username ... etc -- I know my privileges are set so that I can add as much data as I want. Is there a need to set up special privileges for LOAD DATA INFILE? I will note that secure_file_priv is NULL here, and that I am trying to load data from a local file to a remote server.
–
kloopMar 8 '12 at 17:18

I will also note that "SHOW GRANTS" says that I have all privileges.
–
kloopMar 8 '12 at 17:20

@ManseUK I always highlight my code. Must be the DayQuil...
–
msanfordMar 8 '12 at 17:01

1

im actually that anal about the highlighting its annoying me it wraps to a new line !!!!! perhaps i need some DayQuil !!! :-)
–
ManseUKMar 8 '12 at 17:06

@ManseUK Perhaps that's the issue. I usually wrap my code in backticks, but I was sure I clicked the code button this time. Perhaps single-line backtick-wrapped code doesn't get a horizontal scroller?
–
msanfordMar 8 '12 at 17:14