I want to join two table: T1:id,name,email T2:id,address
to join I am doing this:
String hql="select sd.name,tt.name from T1 sd,T2 tt where sd.id=tt.id"; Query q=ss.createQuery(hql); List l2=q.list(); Object o1=l2.get(0); System.out.println("-----------"); System.out.println(o1.toString()); System.out.println("-----------"); It is returning object but dont get how to retrieve the values as returned object is not entity object.