У меня есть клиент: < /p>
Код: Выделить всё
@Entity
public class Client {
@Id
@GeneratedValue(strategy = GenerationType.SEQUENCE)
private BigDecimal id;
@OneToMany(mappedBy = "client",cascade = CascadeType.ALL)
private List orderlist;
< /code>
и заказ: < /p>
@Entity
@EntityListeners(AuditingEntityListener.class)
public class Order implements Serializable{
@Id
@GeneratedValue(strategy = GenerationType.SEQUENCE)
private BigDecimal id;
@ManyToOne
@JoinColumn(name = "client_id")
private Client client_id;
, вызванное: org.hibernate.annotationException: collection 'com.example.demo.entity.client.orderlist' - это «mappenby». /> Любой < /p>
имеет отношение OneTomany и многотонооне. Кто -нибудь может помочь мне, что я неправ?
Подробнее здесь: https://stackoverflow.com/questions/796 ... get-entity