vlookup for access

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I am looking for equivalent functionality on ACCESS XP as found in the
vlookup function in EXCEL. I have a value in a field which I will test
against a table. If the value is found, I want to return, in a new field,
the corresponding value in the table as in a vlookup.
 
Check the dlookup function
dlookup("FieldName","TableName", "Criteria")
if the record is not found then the function will return a NULL.
 
I am looking for equivalent functionality on ACCESS XP as found in the
vlookup function in EXCEL. I have a value in a field which I will test
against a table. If the value is found, I want to return, in a new field,
the corresponding value in the table as in a vlookup.

Excel is a spreadsheet. Access is a relational database. THEY ARE
DIFFERENT. A database is not a big spreadsheet, nor is Access a failed
implementation of Excel!

You can, as Ofer suggests, use the DLookUp function, but probably a
better approach is to use a Query joining the two tables, or a Combo
Box on a form which displays the "looked up" value; either will be
more efficient than DLookUp.

In any case you should certainly NOT store the looked-up value
redundantly in another table field.

John W. Vinson[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

Back
Top