export the xls file with Excel to csv - format and import this csv-file with phpMyAdmin. But - this only works if the format matches. More details will help us to give you better / more tipps. Best regards, Tobias
Yes this is possible.this is very easy to do if you have this tool see this link: forums.digitalpoint.com/showthread.php?t=64150 cheers!
<? $handle = fopen("spreadsheet.csv", "r"); if ($handle) { $array = explode("\n", fread($handle, filesize("spreadsheet.csv"))); } $total_array = count($array); $i = 0; while($i < $total_array) { $data = explode(",", $array[$i]); $sql = "SELECT * FROM `table` WHERE id='" . $data[0] . "' LIMIT 1"; $result = mysql_query($sql); if(mysql_num_rows($result) == 0) { // Put SQL insert statement here } $i++; } Code (markup):
Did a google search and it comes up with this free tool which might be helpful: http://www.easyfrom.net/download/
Did a google search and it comes up with this free tool which might be helpful: http://www.easyfrom.net/download/ Reply With Quote yeah good tool thanx for help looking for this tool and found it after a big search at this forum.
well 2 years later the xls2mysql converter still does the job too. Automatically converts excel data types to mysql data types. http://www.webmasterbulletin.net/xls2mysql
you can just use the program navicat if its just a one time thing. If its done through the website then you have to convert to csv and parse the data out of there.
User have to parse the data is suitable columns One column for each filed in the data base,at each column put (") In the last column of each row end with â€); Next have to be inserted one column foremost of all. And in each row have to enter: INSERTO INTO `TABLE` (`field1`, `field2`, `fieldN`) VALUES( . Next this have to be saved like normal text file and copy & paste in MySql console
You can import xls file to PHP using this library: www.easyxls.com For yantomulia, you can use the same library to export as CSV file from PHP.