I am running the below using a function that sets up the recordset and connects to a database. I know this bit works as I use it all through the DB. The only differance in the below is that it is a more complex query envooving left joins. Can I use a left join like this in a recordset?
Code:
selectQry "TOP 5 Tbl_QC_Results.Matches, Tbl_QC_Results.NoMatches, Tbl_QC_Results.AQL1_Errors, Tbl_QC_Results.AQL2_Errors, tbl_ed_Production_New.Last_QC, tbl_ed_Production_New.QC_Flag, tbl_ed_Production_New.EmpId," & _
"tab.MATCHED", "Tbl_QC_Results LEFT JOIN ((tbl_ed_Production_New LEFT JOIN Block_Definitions ON tbl_ed_Production_New.Block_Name = Block_Definitions.Txt_Block_No) LEFT JOIN tab " & _
"ON Block_Definitions.Nmb_Block_No = AI_CAND_MTN_AI_VOA_CANDIDATE_LIST.JOB_ID) ON Tbl_QC_Results.Block_Number = tbl_ed_Production_New.Block_Name ", " (((tbl_ed_Production_New.Last_QC) Like '[0-9]0') AND " & _
" ((tbl_ed_Production_New.EmpId)= " & [Forms]![Frm_new_QC_Entry_Form]![TxtempID] & " )) OR (((tbl_ed_Production_New.EmpId)= " & [Forms]![Frm_new_QC_Entry_Form]![TxtempID] & " ) AND ((tab.MATCHED)='A')) OR (((tbl_ed_Production_New.QC_Flag) Is Null) AND ((tbl_ed_Production_New.EmpId)= " & [Forms]![Frm_new_QC_Entry_Form]![TxtempID] & " ));"