I need make OUTER JOIN of two entities in JPA (saying master, detail), but the problem that at the entity level there are no relations (and i don't want add it).
@Entity
class Master
{
@Column(name="altKey")
Integer altKey;
}
@Entity
class Detail
{
@Column(name="altKeyRef")
@Basic (optional = true)
Integer altKeyRef;
}
SELECT m, d FROM Master m OUTER JOIN ????? d.altKeyRef = m.altKey