1. Different results fetching results with query api vs. hql stackoverflow.comI have the following entity (not exact but gives a general idea): @Entity public class WebElement implements Serializable { private static final long serialVersionUID = 1L; @Id ... |
2. Hibernate Criteria API results not matching HQL results for left join fetch stackoverflow.comI have 2 simple models:
|
3. How can i retrieve this results forum.hibernate.orgHi, im new to Hibernate and im trying to get this results. String sql = "select count(c.id), c.id from Rooms c group by c.id " List results = getHibernateTemplate().find( sql ); if( results.size() > 0 ) { AnObject o = list.get(0); } where AnObject has the members: Integer count , Long id but it gets me a Cast Error. Object can ... |
4. Custom result object problem LazyException eager fetching forum.hibernate.org |
5. Collection with fetch = EAGER result in many queries forum.hibernate.orgWe have an entity with a Collection that is marked fetch = EAGER. When I query a list of the entity, a query is run for each entity to fill the collection rather than using a join as you would expect with an EAGER. Anybody know under what circumstances hibernate will issue many requests rather than a join? |
6. Hibernate Search results fetching pbm. forum.hibernate.orgHi, In hibernate when we use :- query.setFirstResult (pageParams.getPageNumber() * pageParams.getPageSize()); -> (0*100 = 0) query.setMaxResults (pageParams.getPageSize()); -> (100) This will bring the first 100 records. For the first time, when we click Page 1, hibernate will retrieve the first 0-100 records from the DB. This is fine. When the user clicks the Page 2, hibernate will retrieve 200 records (1-200) ... |
7. empty result from left join fetch forum.hibernate.orgAuthor Message dimulescu Post subject: empty result from left join fetch Posted: Wed Jun 30, 2004 11:02 am Newbie Joined: Wed Aug 27, 2003 2:43 am Posts: 19 Location: Paris Hello, I have 2 classes (Partner and PartnerDetails) connected by a one-to-one association; I run an HQL using LEFT JOIN FETCH in order to retrieve a Partner with its ... |
8. Which is the preferred way of fetching results forum.hibernate.org |
9. Multiple results when using eager fetch in Criteria query forum.hibernate.orgHibernate version: Hibernate 3.1.1 Hibernate Annotations 3.1 beta8 I have defined 2 classes using annotations as follows. Note that the contactNumbers member is eager fetched. Code: @Entity public class ContactNumber { @NotNull String number; String description; } @Entity public class Person { ... @OneToMany(fetch = FetchType.EAGER) ... |
10. Fetching results from PLSQL stored procs forum.hibernate.orgHi, apologies if this has been answered a thousand times. I tried a search and couldn't see the answer (except maybe in German....) We are interested in transitioning to using Hibernate to execute our Oracle queries. Can Hibernate run an Oracle stored procedure and take a result set from it using refcursors? We have a strong desire to keep all SQL ... |
11. Why does join fetching give the wrong result? forum.hibernate.orgAuthor Message vedamen Post subject: Why does join fetching give the wrong result? Posted: Wed Feb 28, 2007 4:58 am Newbie Joined: Wed Feb 14, 2007 5:38 am Posts: 6 Consider the following code Code: @Entity public class Client { @Id @GeneratedValue private int id; ... |
12. Why does join fetching give the wrong result? forum.hibernate.orgAuthor Message vedamen Post subject: Why does join fetching give the wrong result? Posted: Wed Feb 28, 2007 4:59 am Newbie Joined: Wed Feb 14, 2007 5:38 am Posts: 6 Consider the following code Code: @Entity public class Client { @Id @GeneratedValue private int id; ... |