Reputation: 10245
sing the Mac terminal, how could you populate a mysql database when the text file has a format like this.
00000,1284
00001,2081
I have created the database table to reflect that data however I am not sure on how to import a text file with this type of format..
This is what I am trying to use right now but its not working
LOAD DATA INFILE 'Developer/Shared Files/NIS.txt INTO TABLE nisC FIRLDS TERMINATED BY ',';
Upvotes: 2
Views: 3436
Reputation: 15940
Use the statement as below
LOAD DATA INFILE 'Developer/Shared Files/NIS.txt' INTO TABLE nisC (field1, field2);
Upvotes: 3