Query Question...

1

116

I have 2 tables...Job and Material. I am trying to configure dlookup to
return value of 'Note_Text' in table 'Material' based on 'Part_Number' in
table Job.

DLookUp("[Note_Text]","Material","[Material] = [Job]![Part_Number]")

Any help would be greatly appreciated.

Thanks
David
 
A

Allen Browne

Concatenate the value into the criteria string:
=DLookUp("[Note_Text]","Material","[Material] = " &
Nz([Job]![Part_Number],0))
 
R

RonaldoOneNil

Assuming the source for your query is the table Job and Part_Number is a text
field.
Add the Part_Number into your query and then use the following in another
column in your query.

Note Text: DLookUp("[Note_Text]","Material","[Part_Number] = '" &
[Part_Number] & "'")
 
1

116

Thanks for the assist. I see what I was doing wrong.

David

RonaldoOneNil said:
Assuming the source for your query is the table Job and Part_Number is a text
field.
Add the Part_Number into your query and then use the following in another
column in your query.

Note Text: DLookUp("[Note_Text]","Material","[Part_Number] = '" &
[Part_Number] & "'")

116 said:
I have 2 tables...Job and Material. I am trying to configure dlookup to
return value of 'Note_Text' in table 'Material' based on 'Part_Number' in
table Job.

DLookUp("[Note_Text]","Material","[Material] = [Job]![Part_Number]")

Any help would be greatly appreciated.

Thanks
David
 
1

116

Trying to apply this 'MID([MemoField]
,Instr(1,[MemoField],"StartTag")+ Len("StartTag")
,Instr(1+Instr(1,[MemoField],"StartTag"),[MemoField],"EndTag")
-Instr(1,[MemoField],"StartTag") - Len("StartTag"))' to the 'dlookup' with
no success. I can however add another column in the query and get it to
work. I am using this info in a report, yet not in access.

David

116 said:
Thanks for the assist. I see what I was doing wrong.

David

RonaldoOneNil said:
Assuming the source for your query is the table Job and Part_Number is a text
field.
Add the Part_Number into your query and then use the following in another
column in your query.

Note Text: DLookUp("[Note_Text]","Material","[Part_Number] = '" &
[Part_Number] & "'")

116 said:
I have 2 tables...Job and Material. I am trying to configure dlookup to
return value of 'Note_Text' in table 'Material' based on 'Part_Number' in
table Job.

DLookUp("[Note_Text]","Material","[Material] = [Job]![Part_Number]")

Any help would be greatly appreciated.

Thanks
David
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top