Wednesday, 28 August 2013

How to read the data in csv and upload to Mysql

How to read the data in csv and upload to Mysql

I have a file in csv which the format is like following:
"**Table1"
"*Field1","*Field2","*Field3","*Field4"
"Data1","Data2", "Data3", "Data4"
"**Table2"
"*Field1","*Field2","*Field3","*Field4"
"Data1","Data2", "Data3", "Data4"
I want the program can recognise the table 1/ 2 and upload the data to the
mysql predefined table. I plan to use PHP. Has anyone tried to do this? I
looking for an example and method! Thanks.

No comments:

Post a Comment