title: JPA - multi-column unique constraint with null value
body: <pre><code>I have an entity like this
  @Entity
  class Foo {
      long id;
  
       String name;
  
       Double parent_id;
  
       Double super_parent_id;
  
  }
  </code></pre>
  
  <p>And i want this 3 column as a unique key like this : </p>
  
  <pre><code>@Table(name = "FOO", uniqueConstraints={
      @UniqueConstraint(columnNames = {"name", "parent_id","super_parent_id"})
  })
  </code></pre>
  
  <p>but this 2 column ( parent_id , super_parent_id ) are nullable so if i have this data</p>
  
  <pre><code>name        parent_id      super_parent_id
  my_name        1              NULL
  my_name        1              NULL
  </code></pre>
  
  <p>the <code>jpa</code> see this two rows difference and it's logical because NULL IS difference from NULL</p>
  
  <p>but i want them to be validate as same row </p>
  
  <p>Any suggestion ?.
  Thanks</p>