Has client had any minutes of care from head caretaker?
I have two Tables: Clients and Caretakers.
Clients has two fields:
- Clients::PID and
Caretakers has 4 fields:
- Caretakers::PID (which is the client's ID),
The Caretakers-table holds information about which client received how many minutes of time from every caretaker. This can be many lines for 1 client.
Each client has only one Head_Caretaker.
What I would like to be able to do is:
let the field Clients::Head_Caretaker_time show the time, if any, has been spent bij the Head_Caretaker for this client.
The result should look like this:
PID 1, Head_Caretaker_time = 05
PID 2, Head_Caretaker_time = 25
PID 3, Head_Caretaker_time = 0
I other words: for each client show: if Head_Caretaker_ID=Caretaker_ID, then show value of Caretakers::Caretaker_time
Any help? I've tried my first steps with Valuelists but no luck so far.