1. Hibernate Criteria contains-in on an association to a table stackoverflow.comGood day, I have a Hibernate mapping that looks something like this:
|
2. Hibernate Criteria with a one-to-many association stackoverflow.comI have an Order entity (that, well, represnts an order), and each order has a set of DeliveryDates. I'm trying to implement a search function and show the results in ... |
3. Hibernate Criteria with a one-to-many association coderanch.comHi, I have an Order entity (that, well, represnts an order), and each order has a set of DeliveryDates. I'm trying to implement a search function and show the results in a JFace TableViewer. I want that for every order that has more than one delivery date, it should be duplicated in the table, but the DeliveryDate column would display the ... |
4. Criteria API, associations forum.hibernate.orgNewbie Joined: Thu Mar 27, 2008 1:30 pm Posts: 5 Hi, I searched around and found that association mapping seems to be required when using the Critiria API. I'm asking because I have a project using hibernate 3.2 and I'm doing queries like this (HQL): (Entities mapped with annotations) Code: Session session = HibernateHelper.getCurrentSession(); Query query = session.createQuery("SELECT DISTINCT lg FROM ... |
5. Define Disjunction on multiple associations with Criteria? forum.hibernate.orgHi I am creating a search query consisting of multiple associations. I need OR for all fields, I am able to define OR on fields with in an association. But I would also like to define OR on all associations also. Below is the code I am using currently: Code: Criteria customerCriteria = this.getSession().createCriteria(Customer.class); Criteria contactsCriteria = customerCriteria.createCriteria("contacts"); Criteria ordersCriteria = ... |
6. Associations with Criteria forum.hibernate.orghi everyone, here is what I want to do I have two table on my data base Book(bookId,bookTitle,authorId) Author(AuthorId,AuthorName) I want to get list of books that have a particular author (identified by name) here is what I thought of: Code: Criteria ... |
7. Hibernate Criteria with a one-to-many association forum.hibernate.orgHi, I have an Order entity (that, well, represnts an order), and each order has a set of DeliveryDates. I'm trying to implement a search function and show the results in a JFace TableViewer. I want that for every order that has more than one delivery date, it should be duplicated in the table, but the DeliveryDate column would display the ... |
8. Hibernate Criteria, on association, createCriteria, createAl forum.hibernate.orgHi I "have" two classes: Code: class A { B b; // can be null Boolean gender; } class B extends Person { // Person contains firstName, lastName ... String name; } c = session.createCriteria(A.class) Criteria bc = c.createCriteria("b"); // Adding this forces B to be not null and the search will exclude ... |
9. Criteria with 2 associations - how? forum.hibernate.org |
10. Implicit Association Joining - Criteria API forum.hibernate.org |
11. Criteria API w/association table forum.hibernate.orgNewbie Joined: Wed Dec 15, 2004 5:16 am Posts: 4 Location: San Francisco, CA I'm trying to create a Criteria query to select objects that are related via an association table. The following HQL works: Code: String hql = "select distinct person from Person as person" + ... |
12. newbie criteria/association question forum.hibernate.orghi all, I'm trying to create a Criteria query that filters on an association with the criteria class. I'm able to run the query with no problems using simple properties. it's the associations that I'm having troubles with. I'm using Hibernate 2.1.7. I have a Patient class and a set of patient status' for a given patient. I keep a record ... |
13. Criteria not capable of associations? forum.hibernate.org |
14. Criteria on associations forum.hibernate.orgCriteria criteria = session.createCriteria(Product.class); criteria.createAlias("descriptions", "desc"); criteria.add(Restrictions.or(Restrictions.like("desc.title", titleField.getText(), MatchMode.ANYWHERE), Restrictions.like("title", titleField.getText(), MatchMode.ANYWHERE) ... |
15. Hibernate Criteria in One-to-Many Association forum.hibernate.orgI have one-to-many association between ORDER and ITEM. ORDER.ID ORDER.ITEMS ITEM.ID ITEM.PRICE I want to find all the orders when ITEM.PRICE=100 This is my code List tempSets = session.createCriteria(Order.class) .createCriteria("items") .add(Restrictions.eq("price",new Long(100))) .list(); It finds correct number of Orders but when I ask for order.getItems() it gives me all the items for that order and what I need is the order ... |
16. Criteria API:navigate association or duplicated association? forum.hibernate.orgHibernate version: 3.1.3 Mapping documents: |
17. Criteria Many-to-Many Association forum.hibernate.org[b]Hibernate version: 3.2 [/b] [b]Mapping documents: Employee : |
18. One to many association and criteria API forum.hibernate.orgHi! Is the following idea possible using Hibernate/mysql 5: My hibernate objects: Object DVD - Title (- Collection of UserDVDs) Object UserDVD - DVD - User - pricePayed Object User - Username There is a one-to-many association between DVD->UserDVD (is this required at all?) and a many-to-one association between UserDVD -> DVD. I want to display all DVD items from the ... |
19. How to implement join without association in criteria. forum.hibernate.org |