dlookup or iff?

G

Guest

I can't seem to get the following to work. I'm trying to lookup the
information in a table and compare it to a query and return the vale in a
filed in the tabel. If this was excel I just to a vlookup and I'm done, but
there is no vlookup in access, HELP.

iff( [CVR 8TH RUN]![Expr10] = [All Stations]![STN CD] , [All
Stations]![Profit Center] ,"n/a")

or

dlookup( [All Stations]![STN CD] ,Profit Center", [CVR 8TH RUN]![Expr10] )
 
J

Jeff Boyce

I'm not exactly clear where you are trying to do this...

Are you trying to get a value looked up to show up in a table? If so, stop!

Tables (in Access) are great places to store data, but don't work well to
display it.

Forms in Access work great to display data, and give you a way (via
listboxes and comboboxes) to look up values from another table.

Regards

Jeff Boyce
Microsoft Office/Access MVP
 

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

Similar Threads

Should the following IIF statments work? 6
How / When to Create a Table from a Query 11
IIF Functions 2
Append Copy of Table 9
dlookup 1
Look Up Help 3
DLOOKUP command not working 5
Dlookup in query 1

Top