Can a hibernate composite-id (JPA embeddedId) contain nullable columns?

Solution Verified - Updated -

Issue

  • Is it possible to map a composite-id (or EmbeddedId) having nullable columns ? Tests show that if one column value of a particular row is null, then the row isn't transformed into an Entity, null is returned instead of the actual entity.

Environment

  • Hibernate
  • Java Persistence API (JPA)

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.

Current Customers and Partners

Log in for full access

Log In
Close

Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.