title: Query Hibernate Cache instead of database
body: <p>I have a query like:</p>
  
  <pre><code>Select * FROM table1 WHERE name LIKE 's%';
  </code></pre>
  
  <p>I don't want this query to fetch data from database; instead it should return data from hibernate session or something else. I think enabling second level cache will help but not sure that it will help in filtered queries.</p>
  
  <p>How can I force a query not to fetch data from database?</p>