I'm now using a method List<ProjectListBean> getAllProjectListBean() in ProjectDaoHibernate.java to get all ProjectListBean from a ProjectListBean class and I'm having a problem with writing this SQL query in Hibernate:
Code:
SELECT PROJECT.TITLE, CUSTOMER.NAME, GROUP.NAME, DOMAIN.NAME
LEFT JOIN CUSTOMER
ON PROJECT.CUSTOMER_ID=CUSTOMER.ID
LEFT JOIN GROUP
ON PROJECT.GROUP_ID=GROUP.ID
LEFT JOIN DOMAIN
ON PROJECT.DOMAIN_ID=DOMAIN.ID
WHERE PROJECT.CODE is NULL
It's a SQL query LEFT JOIN PROJECT TABLE with three table CUSTOMER, GROUP and DOMAIN.
Can anyone show me how to write this query in hibernate? thank you very much!!!!