Export large CSV file using laravel
问题 I have to export 600k database rows with a belongsTo relationship between two tables to a csv file using a queued job in laravel 5.2, it works fine when I do not include the information from the second table, but it reaches memory limit or timeout I guess (there is no error on the output, the job just stops and the file blocks at ~8MB) when I include the second table. Here is my handle function from my job : public function handle() { $request = $this->request; $ts = Carbon::now()->timestamp;