With JPQL and the Criteria-API I get the exact same result.
Other Entities work for me too, but in this case I use a mapping of derived
identities as specified in JSR 317 section 2.4.1. So, the primary key for my
inventories is another entity (User).
@Entity
public class Inventory implements Serializable {
@Id
@OneToOne(fetch = FetchType.EAGER)
@JoinColumn(name = "Owner", referencedColumnName = "Id")
private User owner;
...
}
--
View this message in context:
http://openjpa.208410.n2.nabble.com/Problem-with-Criteria-API-and-fetch-properties-of-related-entities-are-NULL-tp7582995p7583035.html
Sent from the OpenJPA Users mailing list archive at Nabble.com.