vlookup question please

B

Bob Newman

I think this is vvlookup anyway. I have 3 columns. A has one of several
letters of the alphabet, B has one of about ten different dollar figures, C
is the cell for the lookup amount (commission on a sale).

I want it to figure that if column A contains the letter "N" lookup in a
table to find the commission amount based on the sale amount in column B.
Here's the part that stumps me. I also want the formula to say if column A
has the letter "U" to enter a fixed amount as the commission. Column A may
contain several other letters but "N" and "U" are the only ones I am
interested in.
 
M

Max

Maybe something along these lines ..

Assuming the commission table is
in Sheet2, in A1:B3, viz.:

1 $5.00
100 $10.00
1000 $100.00

In Sheet1
-----------
With col A containing the alphas,
and col B has the amounts

Put in C2:

=IF(A2="","",IF(A2="U",5,IF(AND(A2="N",B2>=1),VLOOKUP(B2,Sheet2!A:B,2,1),"")
))

(above assumes the fixed commission is $5.00, when col A contains "U")

Format C2 as currency and copy down
 

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

Top