Hi, I would like to understand the how Table mapping can be done with Hibernate annotation. I know how to work with one table.If I have multiple table while fetching data then how to map those two tables. Ex : Table1: int emp_id char name Table 2 int dept_id int emp_id char department_name char location.
My result should be like this :
select t2.dept_id,t1.name,t2.department_name from table1 t1,table2 t2 where emp_id = '10002"; Please let me know how to do this.Any examples.Appreciate your time and help.
|