这么改:User表: @OneToMany(mappedBy="user") @Fetch(FetchMode.SUBSELECT) private List orders;Order表: @ManyToOne(fetch = FetchType.LAZY) @JoinColumn(name="userid") private User user;@JoinColumn只需要写在多的一端就行了