Jump to content

Importing Data into MySQL


stan4osu

Recommended Posts

Total newbie to MySQL here - although I have worked with other databases. ---

I created a small db in excel and I just want to import it into MySQL.  the MySQL app is at my hosting site (godaddy.com) and it appears the only option is to import a text file (but there is no other documentation than that).    I have exported my data out of excel to a text file and attempted to import it several times and it won't take it.

I even created a simple 2 field db of VARCHAR fields and tried to load one record and I couldn't.

Can someone please help me with this (apparently) simple task.  I sure don't want to data entry all this data.

Thanks in advance!!
Link to comment
https://forums.phpfreaks.com/topic/31522-importing-data-into-mysql/
Share on other sites

Well you can issue this sql command to do it manually:

[code]LOAD DATA INFILE '/tmp/filename.csv' replace INTO TABLE [table name] FIELDS TERMINATED BY ',' LINES TERMINATED BY '\n' (field1,field2,field3);[/code]

Do you have access to phpmyadmin on your host?

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.