I want all the child records with a compnayid and also parent records different company id. ie. a jsp will display all the records not belong to his company and he can select them and that gets stored with his company id. So next time when displayed it should the already selected ones and all the records from the he does not belong. I tried writing something like this but i get an ewrror
Post your POJOs for Activities and Favorites if they have annotations or mapping files if you are using them instead. Hibernate normally can figure out the join from what I recall, as long as the property used for the join is noted in the annotation or mapping file.