Avatar of W.E.B
W.E.B
 asked on

EXCEL 2007

Hello,
not sure what I'm doing wrong,
Here is the requirement, (I'm trying to copmare sales between periods of 2 years)-
--Column H--
Find Client from Column K in Column C, If the client is found, results ,
(SALES in column M - Sales in column E) --  for the client.
I tried to use =LOOKUP(K3,$C$3:$C$206,$E$3:$E$206) to only get the value of sales (without even the formula), but the results are coming wrong.
Any help is appreciated.


Sales-Comparison.xls
Microsoft SQL Server 2005Microsoft OfficeSpreadsheets

Avatar of undefined
Last Comment
W.E.B

8/22/2022 - Mon
ASKER CERTIFIED SOLUTION
Patrick Matthews

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
W.E.B

ASKER
HI Mathew,
=INDEX(E:E,MATCH(K3,C:C,0))
this works great, how do you add the formula, to get return as
difference, (SALES in column M - Sales in column E)

thanks,
Patrick Matthews

Try this:

=M3-INDEX(E:E,MATCH(K3,C:C,0))

That will return a #N/A error if K3 has no match in Col C.  If you want <Sales in Col E> treated as zero if there is no match:

=M3-IFERROR(INDEX(E:E,MATCH(K3,C:C,0)),0)

Patrick
W.E.B

ASKER
Perfect,
I will be using both for different reports,
thanks.
Experts Exchange has (a) saved my job multiple times, (b) saved me hours, days, and even weeks of work, and often (c) makes me look like a superhero! This place is MAGIC!
Walt Forbes
W.E.B

ASKER
sorry, accepted my own , instead of Patrick.
W.E.B

ASKER
Excellent