need dlookup equivalent of vlookup

andrefrancis

andrefrancis
Local time
Today, 07:00
Joined
Mar 11, 2005
Messages
40
I need to use dlookup in a query to populate a new field "number" with values obtained using a current field "letter". I have a (lookup) table as follows: Col1 = A, B, C, D and Col2 = 1, 2, 3, 4 which of course gives the number code corresponding to each letter.

In Excel, I simply use the formula: vlookup("letter", "lookuptableref", 2, false) and it populates my new field number with the correct values.

Can anyone help me with the equivalent in Access using dlookup?

Thanks!
 
I have solved this particular problem in another way.

Using a query, I 'joined' the lookup table to my main table, used join option 2 and simply selected field 'number' from the lookup. Easy as pie.

However, I would still like to use dlookup to effect the same thing!
 
However, I would still like to use dlookup to effect the same thing!
You shouldn't, what you have is much more efficient, more especially in a query ;)
 

Users who are viewing this thread

Back
Top Bottom