'About the use of JPA ElementCollection
I used the ElementCollection annotation on a List
object,
@ElementCollection(fetch = FetchType.EAGER)
@CollectionTable(
name = "a",
joinColumns = {@JoinColumn(name = "a_id", referencedColumnName = "a_id")},
foreignKey = @ForeignKey(name = "none", value = ConstraintMode.NO_CONSTRAINT)
)
private List<b> bs;
public class b{
@Column
private String bId;
@Column
private String bName;}
Is there a way to create a query dynamically through the name attribute in b by creating a Predicate
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
Solution | Source |
---|