...

View Full Version : importing data into mysql



sudhakararaog
01-22-2008, 04:12 AM
hi

i need to import data into a table in mysql from phpmyadmin using the
Import option instead of using insert statements.

for example if the table has 10 fields should the file that needs to
be uploaded have the same field names on top and the associated values.

ideally should this be as an excel or csv file or text file.

in each case please advice the format in which the data needs to be
added into the csv/txt file.

please advice.

thanks.

Erindesign
01-22-2008, 04:17 AM
I don't understand...

You are importing from excel into mysql? If so, I'm not familiar with how excel has the output format, but I don't think it will be possible without altering the file.

the MySQL imports use strictly SQL code. That's that "INSERT INTO BLA BLA BLA"...

so if u can code sometihng that will alter the data and put it into sql form, or do it by hand, you're screwed.

o0O0o.o0O0o
01-22-2008, 05:03 AM
That means you have table already created

In that case you use csv file to import data in sql and just dive the
delimiters in the options

There are ready made scripts also available to import data in sql



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum