php - Laravel-Excel massive import -


so, have excel file 28k rows.
want load it, insert database, stopped. (blank space)
i've tried reduce 5k data, , worked, slow
tried using chunk, 5k data, got "maximum execution time of 300 seconds exceeded".
here's code

excel::filter('chunk')->load(storage_path('excel/exports/').$filename)->chunk(1000, function($results)     {         foreach($results $key)         {             // nothing         }     }); 

is 5k row big handle?
or doing wrong?
thanks.

you're doing book. (using chuck, example)
28k rows data handle.

you can edit maximum execution time.
see: http://php.net/manual/en/function.set-time-limit.php

bool set_time_limit ( int $seconds ) 

hope help.


Comments