Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1
Default Trying to lookup based on a condition of two values

I have three columns A, B and C.

I want too look up the value in C where A and B match different values.

Example:

A, B ,C
apple, color, green
apple , price, 30
lemon, taste, tangy
lemon, price 20

I want to lookup A=apple B=price to return the price 30.
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 15,768
Default Trying to lookup based on a condition of two values

Assuming that the combination of A + B is unique...

=SUMPRODUCT(--(A2:A10="apple"),--(B2:B10="price"),C2:C10)

Better to use cells to hold the criteria.

E2 = apple
F2 = price

=SUMPRODUCT(--(A2:A10=E2),--(B2:B10=F2),C2:C10)

--
Biff
Microsoft Excel MVP


"Trying to lookup based on a condition of" <Trying to lookup based on a
condition wrote in message
...
I have three columns A, B and C.

I want too look up the value in C where A and B match different values.

Example:

A, B ,C
apple, color, green
apple , price, 30
lemon, taste, tangy
lemon, price 20

I want to lookup A=apple B=price to return the price 30.



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
CountIf Condition based on lookup in a list of values Eric E Excel Worksheet Functions 6 April 22nd 23 12:12 AM
Sum table values based on condition SCC Excel Worksheet Functions 2 December 2nd 08 06:29 PM
How to average values based on a condition in another column Ken99 Excel Worksheet Functions 2 November 16th 06 03:38 PM
Sumproduct - Condition based on lookup of a Lookup Hari Excel Discussion (Misc queries) 12 May 31st 06 09:28 AM
Cannot sum values based on condition Ned Flanders Excel Worksheet Functions 1 December 3rd 04 04:36 AM


All times are GMT +1. The time now is 05:56 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"