title: How I can Process Big number of records with Laravel eloquent and MySql without server fails?
body: <p>The problem is that I have a huge list of emails (750,000 verified Emails ) and I want to loop on it against a users table that also has a huge number of records (800,000 users) and delete users that their
  emails is not exists in the verified email list I tried to to use chunks , but I think I use it in wrong way, For example :</p>
  <pre><code>$users = User::query()-&gt;wherehas('emails_email')-&gt;chunk(10, function ($users) {
      foreach ($users as $user) {
            
          echo $user-&gt;name ;
       }
  });
  return response()-&gt;json($users) 
  </code></pre>