title: Laravel eloquent get model on date
body: <p>I want to get all users created on a specified date:</p>
  
  <pre><code>// $date is a Carbon instance parsed from command line argument.
  // I checked it and it is correct.
  
  $users = User::where('created_at', '&gt;', $date-&gt;startOfDay())
      -&gt;where('created_at', '&lt;', $date-&gt;endOfDay())
      -&gt;get();
  </code></pre>
  
  <p>But this returns 0 results, whereas in the database there are rows that correspond to that date.</p>
  
  <p>What am I doing wrong?</p>