I have two entities Enterprise and EnterpriseGroupDefault. Enterprise is the parent entity. EnterpriseGroupDefault has composite primary keys. Its mapping is given below:
Now when I execute session.createQuery("from Enterprise") HQL, it executes successfully but it also fetches the child entity(EnterpriseGroupDefault), which I do not want to happen. Can anyone suggest what is going wrong here?
We find this kind of rampant individuality very disturbing. But not this tiny ad: