G
Guest
I am using the below string in VBA to generate the SQL for a select query.
I would like to change this so I can append this data to
tlbContractReviewControl. I have tried searching in the help guide but I cant
find anything. Can anyone help?
strSQL = "SELECT tblContracts.ContractID, tblContracts.SupplierID,
tblSuppliers.SupplierName, " & _
"tblContracts.ContractDescription, tblContracts.StartDate,
tblContracts.EndDate, tblContracts.NoticePeriod, " & _
"tblContracts.ReviewDate, tblContracts.FinancialCommitment,
tblContracts.ContractNotes, tblOwners.FirstName, " & _
"tblOwners.LastName, tblOwners.Email, tblCommodity.CommodityGroup,
tblPurchasingRoles.Email " & _
"FROM ((tblSuppliers LEFT JOIN tblCommodity ON
tblSuppliers.CommodityID = tblCommodity.CommodityID) " & _
"LEFT JOIN tblPurchasingRoles ON tblCommodity.StaffID =
tblPurchasingRoles.StaffID) " & _
"INNER JOIN (tblOwners RIGHT JOIN tblContracts ON tblOwners.OwnerID
= tblContracts.OwnerID) " & _
"ON tblSuppliers.SupplierID = tblContracts.SupplierID " & _
"WHERE " & strExpired & strCommodity & "
tblContracts.AnnulledContract Is Not Null;"
I would like to change this so I can append this data to
tlbContractReviewControl. I have tried searching in the help guide but I cant
find anything. Can anyone help?
strSQL = "SELECT tblContracts.ContractID, tblContracts.SupplierID,
tblSuppliers.SupplierName, " & _
"tblContracts.ContractDescription, tblContracts.StartDate,
tblContracts.EndDate, tblContracts.NoticePeriod, " & _
"tblContracts.ReviewDate, tblContracts.FinancialCommitment,
tblContracts.ContractNotes, tblOwners.FirstName, " & _
"tblOwners.LastName, tblOwners.Email, tblCommodity.CommodityGroup,
tblPurchasingRoles.Email " & _
"FROM ((tblSuppliers LEFT JOIN tblCommodity ON
tblSuppliers.CommodityID = tblCommodity.CommodityID) " & _
"LEFT JOIN tblPurchasingRoles ON tblCommodity.StaffID =
tblPurchasingRoles.StaffID) " & _
"INNER JOIN (tblOwners RIGHT JOIN tblContracts ON tblOwners.OwnerID
= tblContracts.OwnerID) " & _
"ON tblSuppliers.SupplierID = tblContracts.SupplierID " & _
"WHERE " & strExpired & strCommodity & "
tblContracts.AnnulledContract Is Not Null;"