title: How to select if a row exists in HQL
body: <p>EDIT: Specifically talking about querying against no table.  Yes I can use exists, but I'd have to do </p>
  
  <pre><code>select case when exists (blah) then 1 else 0 end as conditionTrue
  from ARealTableReturningMultipleRows
  </code></pre>
  
  <hr>
  
  <p>In T-SQL I can do:</p>
  
  <pre><code>select case when exists(blah) then 1 else 0 end as conditionTrue
  </code></pre>
  
  <p>In Oracle I can do:</p>
  
  <pre><code>select case when exists(blah) then 1 else 0 end as conditionTrue from DUAL
  </code></pre>
  
  <p>How can I achieve the same thing in HQL?</p>
  
  <p>select count() seems like the second-best alternative, but I don't want to have to process every row in the table if I don't need to.</p>