
February 22nd, 2000, 12:33 PM
|
|
Junior Member
|
|
Join Date: Jan 2000
Location: Lakewood, CO, USA
Posts: 8
Time spent in forums: < 1 sec
Reputation Power: 0
|
|
|
<BLOCKQUOTE><font size="1" face="Verdana,Arial,Helvetica">quote:</font><HR>Originally posted by gszczyrb:
I have a small Access database that I am attempting to export to MySQL. My service provider has MySQL and PHP on the server already. I am familar with table creation etc... However, I can't seem to get the import to work properly. I keep getting parse errors. I've exported the Access databse to a text file. Then I attempt the import into MySQL and I get a error message like this:
MySQL said: parse error near 'n' ' at line 1
I'm using an automated Control panel to do the import. I've tried doing it in the shell too. Any help will be greatly appreciated.
[/quote]
Log into the server: $mysql -u yourname yourdbname<cr>
password: *******
mysql>
Use this set of code, and you will be find.
load data infile "/usr2/mysql/lube/import_data/vehicle1.txt" into table vehicle fields terminated by ',' enclosed by '"' lines terminated by 'n'
The file "vehicle1.txt" is a "comma-delimited file", where ALL FILES are surrounded by quotes and separated by commas.
|