join « MySQL « JPA Q&A





1. Using a view as a join table with Hibernate    stackoverflow.com

I've got two entities which I want to join via a common String. I've created a view which I want to use as the join table. This all works fine except for ...

2. Cross database joins in JPA    stackoverflow.com

Is it possible to do cross database table joins in JPA? I have a users table in one database which has a foreign key to a organizations table in a separate ...

3. reached join limitation for mysql    forum.hibernate.org

Hi, I work on a application which handles several (about 45) kinds of equipments. All those equipments have common behaviors and are described in a hierarchy of classes with about 3 depth level. I create a mapping file using joined-subclass because all thoses equipments have differents attributs and many-to-one associations. I take care of number of levels in the mapping file ...

4. how to create HQL with LEFT JOIN ... ON ... (MySQL)    forum.hibernate.org

what version of mysql? (i assume you can't upgrade...) hql should be able to represent it as you showed it in the first part without the not in. alternatively, using criteria should not cause this either. you should be able to represent it as SELECT u.* FROM jpt_user u LEFT JOIN jpt_tw_user tu ON u.id=tu.user_id and tu.user_id = NULL your second ...

5. mysql double left join returns wrong result    forum.hibernate.org

this is test class: Code: package foo; import org.hibernate.Query; import org.hibernate.Session; import org.hibernate.SessionFactory; import org.springframework.context.ApplicationContext; import org.springframework.context.support.ClassPathXmlApplicationContext; import java.util.List; public class JoinTest { private SessionFactory sessionFactory; public void setSessionFactory(SessionFactory sessionFactory) { this.sessionFactory = sessionFactory; } public static ...