title: JPQL between dates
body: <p>I have a database table which has two columns <code>DATE_START</code> and <code>DATE_END</code>.</p>
  
  <p>Now I want to find all entries where a <code>Date</code> is between <code>DATE_START</code> and <code>DATE_END</code>.</p>
  
  <p>Example:</p>
  
  <p><code>ID | DATE_START | DATE END
   1  | 2015-1-1   | 2015-1-10</code></p>
  
  <p>Lets say i want to query with <code>MYDATE = 2015-1-5</code> then I would like the database to return row number <code>1</code></p>
  
  <p>I tried the following query:</p>
  
  <p><code>select * from table where DATE_START &gt;= MYDATE and DATE_END &lt;= MYDATE</code></p>
  
  <p>However this does not return the row because <code>DATE_START</code> will not match</p>