title: Mapping Java boolean to Oracle Number column with JPA and Hibernate
body: <p>I have a property created like this in my model:</p>
  
  <pre><code>    public class Client {
          private Boolean active;
  }
  </code></pre>
  
  <p>My RDBMS is Oracle and the <code>active</code> column is of type <code>NUMBER(1,0)</code>.</p>
  
  <p>How can I use the Restrictions API to achieve the following functionality?</p>
  
  <pre><code>criteria.add(Restrictions.eq("active"),object.isActive());
  </code></pre>