J
Joseph Atie
I currently have 3 queries that id like to combine into a single nested query
to run from vba.
in access i created a 2 queries that join 2 tables,
qry1:
"SELECT Transdata.Transcode, Transdata.Barcode, Equipment!Name & "" "" &
Equipment!Type AS Description FROM Equipment LEFT JOIN Transdata ON
Equipment.Barcode = Transdata.Barcode where Transdata.Barcode = " & bcode &
";"
qry2:
"SELECT Users![First Name] & "" "" & Users!Surname AS Name FROM Users LEFT
JOIN Transactions ON Users.Usercode = Transactions.Usercode where
transaction.usercode = " & ucode & ";"
i then created a 3rd query that joins the first to queries.
qry3
SELECT Query2.Name, Query3.Description
FROM Query2 INNER JOIN Query3 ON Query2.Transcode = Query3.Transcode;
I know i can use the first 2 queries to produce the answer im looking for.
but id like for my own learning to understand how to put these together into
the third query.
help please
to run from vba.
in access i created a 2 queries that join 2 tables,
qry1:
"SELECT Transdata.Transcode, Transdata.Barcode, Equipment!Name & "" "" &
Equipment!Type AS Description FROM Equipment LEFT JOIN Transdata ON
Equipment.Barcode = Transdata.Barcode where Transdata.Barcode = " & bcode &
";"
qry2:
"SELECT Users![First Name] & "" "" & Users!Surname AS Name FROM Users LEFT
JOIN Transactions ON Users.Usercode = Transactions.Usercode where
transaction.usercode = " & ucode & ";"
i then created a 3rd query that joins the first to queries.
qry3
SELECT Query2.Name, Query3.Description
FROM Query2 INNER JOIN Query3 ON Query2.Transcode = Query3.Transcode;
I know i can use the first 2 queries to produce the answer im looking for.
but id like for my own learning to understand how to put these together into
the third query.
help please