Hibernate query gives same record multiple times

前端 未结 6 733
再見小時候
再見小時候 2021-02-07 06:30

I am working on hibernate in eclipse. I am executing simple \'From\' query. Here is the code

  List list = sess1.createQuery(\"From Myview\").list();
    System.         


        
6条回答
  •  野趣味
    野趣味 (楼主)
    2021-02-07 07:23

    If you have association in the mapping then check if fetch=FetchType.EAGER. If yes then use other fetch type or fetchMode.

提交回复
热议问题