As I put in my intro post, I often have trouble with syntax. Its so basic I know there is an expert here who can help.
I have 2 queries that have all the data I want.
The first query's data has been turned into a form.
-The 2nd query has multiple values of the same information and is broken out by a unique ID number called Risk_ID and has
only values 1-55.
I want to add an unbound field from the 2nd query using a basic Dlookup with multiple criteria, that will give me the
Total_Score, dependent on the Job_Station and the Risk_ID.
The following code works but only gives me the first Total_Score as it relates to the job stations
=DLookUp("[Total_Score]","qry_LineSummaryScore","[Job_Station] =" & [Job_Station])
This code gives me only the very first Total_Score whose Risk_ID is 2, regardless of the Job Station.
The syntax of the following code is wrong because it again only gives me the very first Total_Score whose Risk_ID is 2,
regardless of the Job Station.
=DLookUp("[Total_Score]","qry_LineSummaryScore","[Job_Station] =" & [Job_Station] And "[Risk_ID]=" & 2)
All fields are Numbers, no text values.
I must have looked at every example available on this site and others, and read the syntax description a dozen or so times.
It just isn't clicking in my head. Some direction is appreciated.