I've posted a similar question, now, i'd like to ask a theorical question.
Suppose i have a table Organization with orgId (pk) and orgName as it's columns.
I also have a table Employee with empId (pk), empName and fk_orgId (foreign key to Organization).
Organization has 0..* Employees
Employees belons to 1 Organization
Is there a way i can have a method
Code:
private List emps;
...
public List getEmployees(){
return emps;
}
inside Organization class, even if Organization doesn't map the attribute emps to the database (as it's the employees are the many part of the relation)???
Thanks,
ltcmelo