I am pulling data from a IDX/RETS server and trying to insert the data into my own MySQL data base using php.
The data comes in as multiple associative arrays and i loop through them entering each array into its own row.
The table itself has 215 columns, in my first test I only pull 10 records/array's and after running my script I only get 1 row entered.
I have been able to get all 10 rows to insert but only by reducing the number of columns to about 6. For what ever reason when trying to enter all 215 columns of the 10 records it keeps timing out.
I have tried:
ini_set('max_execution_time', 500);
&
set_time_limit(0);
I have also tried entering these values into my php.ini file but what ever i do the script only seems to run for about 15-30 seconds.
Is there something else I am missing or should be doing when entering so many columns??
My code is just a simple while loop that is looping through the arrays. And my insert is like this:
$sql = "INSERT INTO rets_property_residentialproperty";
$sql .= " (`".implode("`, `", array_keys($my_array))."`)";
$sql .= " VALUES ('".implode("', '", $my_array)."') ";
$result = mysqli_query($dbcon, $sql) or die(mysql_error());