1.detached the Cartesian product is produced in the case of the Jion explicit left outer connection query in the crawl strategy
Detachedcriteria DC = Detachedcriteria.forclass (topic.class); Dc.add (Restrictions.like ("title", "percent")); Criteria = Dc.getexecutablecriteria (session); Criteria.setfirstresult ((currentpage-1) * pagesize); Criteria.setmaxresults (pagesize); list<topic> list = Criteria.list ();
The results from the above query under join are
There is a Cartesian product phenomenon, so when using separate query paging if lazy is false should try to use Subselect or select crawl policy
Detailed hibernate retrieval methods, crawl strategies, and the use of level two cache to optimize and resolve database transaction concurrency problems:HTTP://BLOG.CSDN.NET/U013087513/ARTICLE/DETAILS/69371833?UTM _source=tuicool&utm_medium=referral
Hibernate detached separation query and crawl strategy considerations