Magento, Laravel, Eloquent.
Using cursor // when using eloquent foreach (Product::cursor() as $products){ // Process a single products } // when using query builder foreach (DB::table('Products')->cursor() as $products){ // Process a single products } The above example will make a single database query, retrieve all the