For example:
@Entity(name = "Person") @IdClass(PersonId.class) public static class Person implements Serializable { @Id private String name; @Id @Column( name = "ind") private int index; private Integer id; }
Executing the following query results in a NullPointerException: s.createQuery( "from Person p where p.id is null", Person.class ).list()