title: Simple JPA 2 criteria query "where" condition
body: <p>I'm learning jpa-hibernate basics. </p>
  
  <p>I have this query for getting all users:</p>
  
  <pre><code>CriteriaBuilder cb = getEntityManager().getCriteriaBuilder();
          CriteriaQuery cq = cb.createQuery();
          cq.select(cq.from(Utente.class));
          return getEntityManager().createQuery(cq).getResultList();
  </code></pre>
  
  <p>Now I want to filter by a boolean field named 'ghost' where it equals true (or false, it depends).</p>
  
  <p>Translated: </p>
  
  <blockquote>
    <p>SELECT * FROM users WHERE ghost = 0;</p>
  </blockquote>
  
  <p>Do I have to use cq.where() ? How?</p>