Dlook up is failing with queries

MilaK

Registered User.
Local time
Today, 12:21
Joined
Feb 9, 2015
Messages
285
Hello,

I'm trying to look-up calculated field "items" from "qrysamplecount" query and display it in another query "qryProjectDlookup". I'm not sure why it's not working.

The first query is called "qrysamplecount" and returns the number of samples for each project and the main query is called "qryProjectDlookup".

I'm using Dlookup instead of connecting the two queries because I plan to use this query a row source that can be modified by the user.

An example is attached.

Thank you for you help,

Mila
 

Attachments

The qualifier [qrysamplecount] doesn't make sense. Try

Code:
Samplecount: DLookUp("[Items]","[qrysamplecount]","[run_name]= '" & [run_name] & "'")

instead of

Code:
Samplecount: DLookUp("[Items]","[qrysamplecount]","[run_name]= '" & [qrysamplecount]![run_name] & "'")
 

Users who are viewing this thread

Back
Top Bottom