I have two entities
我有两个实体
Class A{
@OneToMany(mappedBy = "a", cascade = CascadeType.REMOVE)
private List<B> b;
private Integer credits;
//other fields
}
Class B{
@ManyToOne
@JoinColumn(name = "a_fk")
private A a;
private Integer reputations;
//other fields
}
Class A{
@OneTo