|
|
| more useful options | |
| PerlMonks |
Re: How to insert a tab delimited text file to a mysql databaseby Withigo (Friar) |
Log inCreate a new userThe Monastery GatesSuper Search Seekers of Perl WisdomMeditationsPerlMonks Discussion ObfuscationReviewsCool Uses For PerlPerl NewsQ&ATutorials PoetryRecent ThreadsNewest NodesDonateWhat's New |
| on Apr 16, 2006 at 23:59 UTC ( #543731=note: print w/ replies, xml ) | Need Help?? |
|
in reply to How to insert a tab delimited text file to a mysql database
Since you said it's a one-time script, perl may be overkill for what can be done in one or two shell commands. Populate it with the data file: Replace [ database name ] with the database you are using, and [ username ] with your mysql username. What you are trying to acheive with $count appears to be handled automatically by the REPLACE part of the LOAD DATA command.
|
|
||||||||||||||