Hello all, here's my problem.
I have a semi-complicated view on my DB. The view contains a couple left joins in it that denormalize about 4 tables. This view, being de-normalized, has several columns and there is no really PK (since views don't need PK)
The question is how do I map this view to Hibernate? Below is an example of what I mean...
BigView_view
employee ID
employee Name
courseTaken
courseID
dateCompleted
...
In the BigView_view an employee can take multiple courses, and he/she can also take a single course multiple times. This makes the composite key (emloyeeID, and coursesID) not unique.
So the key must be the composite of (employeeID, coursesID, dateCompleted). HOWEVER, since the view was created with left joins there is possibility that the courseID and dateCompleted could be null. Reason it can be is because I also want to see the employees who haven't taken certain courses.
HELLPPPPP... any would be grateful.
B
|