D
DS
I have two queries, one based on another.
The first query is this.
And is called "QHasChecks"
SELECT tblChecksTMP.ChkTabID, tblChecksTMP.ChkPaid,
tblChecksTMP.ChkServer, tblChecksTMP.ChkPrinted,
tblChecksTMP.ChkDividedCheck, tblChecksTMP.ChkTypeID,
tblChecksTMP.ChkCancelled
FROM tblTabs INNER JOIN tblChecksTMP ON tblTabs.TabID =
tblChecksTMP.ChkTabID
WHERE (((tblChecksTMP.ChkPaid)=0) AND ((tblChecksTMP.ChkPrinted)=0) AND
((tblChecksTMP.ChkDividedCheck)=0) AND ((tblChecksTMP.ChkTypeID) Not
Like 5) AND ((tblChecksTMP.ChkCancelled)=0));
The second query is this.
SELECT tblEmployees.EmployeeID, [EmpFirstName] & " " & [EmpLastName] AS SRV
FROM QHasChecks INNER JOIN tblEmployees ON
QHasChecks.ChkServer=tblEmployees.EmployeeID
GROUP BY tblEmployees.EmployeeID, [EmpFirstName] & " " & [EmpLastName]
ORDER BY [EmpFirstName] & " " & [EmpLastName];
I need to replace the first querys references in the second query with
SQL code, how would I do this?
Thanks
DS
The first query is this.
And is called "QHasChecks"
SELECT tblChecksTMP.ChkTabID, tblChecksTMP.ChkPaid,
tblChecksTMP.ChkServer, tblChecksTMP.ChkPrinted,
tblChecksTMP.ChkDividedCheck, tblChecksTMP.ChkTypeID,
tblChecksTMP.ChkCancelled
FROM tblTabs INNER JOIN tblChecksTMP ON tblTabs.TabID =
tblChecksTMP.ChkTabID
WHERE (((tblChecksTMP.ChkPaid)=0) AND ((tblChecksTMP.ChkPrinted)=0) AND
((tblChecksTMP.ChkDividedCheck)=0) AND ((tblChecksTMP.ChkTypeID) Not
Like 5) AND ((tblChecksTMP.ChkCancelled)=0));
The second query is this.
SELECT tblEmployees.EmployeeID, [EmpFirstName] & " " & [EmpLastName] AS SRV
FROM QHasChecks INNER JOIN tblEmployees ON
QHasChecks.ChkServer=tblEmployees.EmployeeID
GROUP BY tblEmployees.EmployeeID, [EmpFirstName] & " " & [EmpLastName]
ORDER BY [EmpFirstName] & " " & [EmpLastName];
I need to replace the first querys references in the second query with
SQL code, how would I do this?
Thanks
DS