title: Query fails in Laravel but works in MySQL
body: <p>I have some query scope methods defined in an Eloquent model and am calling them in the controller to allow Laravel to build the query using </p>
  
  <pre><code>return View::make('credit_apps/view')-&gt;with('creditApps', CreditApp::ApprovalStatus()
                                       -&gt;SalesRep()
                                       -&gt;Submitted()
                                       -&gt;RefReceived()
                                       -&gt;get()
                                       );
  </code></pre>
  
  <p>The error returned by Illuminate is a MySQL syntax error:</p>
  
  <pre><code>Illuminate \ Database \ QueryException SQLSTATE[42000]: Syntax error
  or access violation: 1064 You have an error in your SQL syntax; check
  the manual that corresponds to your MySQL server version for the right
  syntax to use near '' at line 1 (SQL: select * from `credit_apps`
  where `approval_status` = 'Approved' and `sales_rep` = 'Joe Smith' and
  `date_received` between '2014-04-30 00:00:00' AND '2014-05-15
  00:00:00' and `date_ref_received` between '2014-04-27 00:00:00' AND
  '2014-05-30 00:00:00')
  </code></pre>
  
  <p>However when I parse the query in MySQL Workbench or from the command line it parses just fine although the criteria returns no records, but I knew it wouldn't. Nevertheless, it's a valid query and works fine in MySQL.</p>
  
  <p>What is causing Laravel to throw the error?</p>