View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Kim B. Kim B. is offline
external usenet poster
 
Posts: 3
Default vlookup with two lookup values?


Thank you, you saved me a ton of time.


"T. Valko" wrote:

Still an array formula:

=IF(ISNA(MATCH(1,(A1:A100=E1)*(B1:B100=F1),0)),0,I NDEX(C1:C100,MATCH(1,(A1:A100=E1)*(B1:B100=F1),0)) )

--
Biff
Microsoft Excel MVP


"Kim B." wrote in message
...
Thank you that did work. If you don't mind I would like to ask you one
more
related question. Right now the formula returns a n/a if there was not
any
data for a location on a specific day, is there a way to change it so it
would return '0' in those cases?

"T. Valko" wrote:

Try this array formula** :

column A = dates
column B = unit location number
column C = data to return

E1 = lookup date
F1 = lookup unit location number

=INDEX(C1:C100,MATCH(1,(A1:A100=E1)*(B1:B100=F1),0 ))

** array formulas need to be entered using the key combination of
CTRL,SHIFT,ENTER (not just ENTER)

--
Biff
Microsoft Excel MVP


"Kim B." wrote in message
...
I am not sure if this is possible or not. I have an extensive list of
data
in which one column I have dates and the next column I have a unit
location
number. I was wondering if it would be possible using a vlookup to
return
values for a specific date for a specific unit location number.