首页 > FetchType.LAZY+@Fetch(FetchMode.JOIN)和fetch = FetchType.EAGER区别

FetchType.LAZY+@Fetch(FetchMode.JOIN)和fetch = FetchType.EAGER区别

fetch = FetchType.LAZY加@Fetch(FetchMode.JOIN),和fetch = FetchType.EAGER有什么区别?
例如:

@OneToMany(fetch =FetchType.LAZY)
@Fetch(FetchMode.JOIN)

@OneToMany(fetch=FetchType.EAGER)

有什么区别?分别在什么情形下使用?

【热门文章】
【热门文章】