S
scottchampion
I've got the following two queries:
Query1:
qsub1.PeriodStartDate
qsub1.EmployeeID
Query2:
qTotWkly.PeriodStartDate
qTotWkly.EmployeeID
qTotWkly.Response
I need to display all of the PeriodStartDate and EmployeeID
combinations contained in Query1. If the PeriodStartDate and
EmployeeID combination occurs in Query2 then I need to display the
respective Response. If the PeriodStartDate and Employee ID
combination does not occur in Query2 then I need to display Null or
zero.
The problem that I have is that I cannot come up with a way to join
Query1 and Query2 that will allow me to give the correct results.
Any ideas on how to handle this?
Query1:
qsub1.PeriodStartDate
qsub1.EmployeeID
Query2:
qTotWkly.PeriodStartDate
qTotWkly.EmployeeID
qTotWkly.Response
I need to display all of the PeriodStartDate and EmployeeID
combinations contained in Query1. If the PeriodStartDate and
EmployeeID combination occurs in Query2 then I need to display the
respective Response. If the PeriodStartDate and Employee ID
combination does not occur in Query2 then I need to display Null or
zero.
The problem that I have is that I cannot come up with a way to join
Query1 and Query2 that will allow me to give the correct results.
Any ideas on how to handle this?