I have a problem calculating the last discount rate, you can see in column F, you can select whatever Item from the item list, in this case I selected Bellen, if you purchase less than 100 units of bellen, you pay the wholesale cost of $25, if you purchase more than 100 units but less than 250 units, you get a 5% discount on the price per unit for that item, and if you purchase over 250 units, you get an additional 5% discount.
The formula below works up until the second discount, in cell H2, 300 units were purchased which means the buyer is entitled to both discounts on the cost per unit, total cost is derived by 300 x (1-5%) x (1-5%) x $25 = $6,768.75 is the correct answer.
[TABLE="width: 844"]
<tbody>[TR]
[TD="align: center"][/TD]
[TD="align: center"]A[/TD]
[TD="align: center"]B[/TD]
[TD="align: center"]C[/TD]
[TD="align: center"]D[/TD]
[TD="align: center"]E[/TD]
[TD="align: center"]F[/TD]
[TD="align: center"]G[/TD]
[TD="align: center"]H[/TD]
[TD="align: center"]I[/TD]
[TD="align: center"]J[/TD]
[/TR]
[TR]
[TD="align: center"]1[/TD]
[TD="align: center"]Item List[/TD]
[TD="align: center"]Units Discount 1[/TD]
[TD="align: center"]Units Discount 2[/TD]
[TD="align: center"]Wholesale Cost[/TD]
[TD="align: center"]Discount Rate 1[/TD]
[TD="align: center"]Discount Rate 2[/TD]
[TD="align: center"]Item Purchased[/TD]
[TD="align: center"]Total Units[/TD]
[TD="align: center"]Per Unit[/TD]
[TD="align: center"]Total Cost[/TD]
[/TR]
[TR]
[TD="align: center"]2[/TD]
[TD="align: center"]Bellen[/TD]
[TD="align: center"]100[/TD]
[TD="align: center"]250[/TD]
[TD="align: center"]$25[/TD]
[TD="align: center"]5.0%[/TD]
[TD="align: center"]5.0%[/TD]
[TD="align: center"]Bellen[/TD]
[TD="align: center"]300[/TD]
[TD="align: center"] $25[/TD]
[TD="align: center"]#REF![/TD]
[/TR]
[TR]
[TD="align: center"]3[/TD]
[TD="align: center"]Carlota[/TD]
[TD="align: center"]100[/TD]
[TD="align: center"]200[/TD]
[TD="align: center"]$25[/TD]
[TD="align: center"]5.0%[/TD]
[TD="align: center"]5.0%[/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[/TR]
[TR]
[TD="align: center"]4[/TD]
[TD="align: center"]Majestic[/TD]
[TD="align: center"]50[/TD]
[TD="align: center"]150[/TD]
[TD="align: center"]$50[/TD]
[TD="align: center"]10.0%[/TD]
[TD="align: center"]15.0%[/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[/TR]
[TR]
[TD="align: center"]5[/TD]
[TD="align: center"]Sunset[/TD]
[TD="align: center"]75[/TD]
[TD="align: center"]150[/TD]
[TD="align: center"]$75[/TD]
[TD="align: center"]15.0%[/TD]
[TD="align: center"]10.0%[/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[/TR]
[TR]
[TD="align: center"]6[/TD]
[TD="align: center"]Phenolic[/TD]
[TD="align: center"]150[/TD]
[TD="align: center"]250[/TD]
[TD="align: center"]$20[/TD]
[TD="align: center"]5.0%[/TD]
[TD="align: center"]10.0%[/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[/TR]
[TR]
[TD="align: center"]7[/TD]
[TD="align: center"]Zapper[/TD]
[TD="align: center"]200[/TD]
[TD="align: center"]350[/TD]
[TD="align: center"]$15[/TD]
[TD="align: center"]5.0%[/TD]
[TD="align: center"]10.0%[/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[/TR]
</tbody>[/TABLE]
In cell J2, I get a #REF!, now below is the formula I have in cell J2, the highlighted red part is the part that works if units are below 100 and or 250, but once over 250, it does not work, I looked at it on formula evaluator, it goes astray when it starts evaluating the third IF formula. The reason I use this formula is because I want to be able to select any product form the list and type in the units which will then give me the total cost based on the criteria. I think I might have the parenthesis in the wrong place or used one more index function than needed.
IF(H2<INDEX(B2:B7,MATCH(G2,A2:A7,0)),H2*I2<index(b2:b7,match(g2,a2:a7,0)),h2*i2,< strong="">,IF(H2</index(b2:b7,match(g2,a2:a7,0)),h2*i2,<><index(c2:c7,match(g2,a2:a7,0)),<index(b2:b7,match(g2,a2:a7,0)),h2*i2,< strong=""><index(c2:c7,match(g2,a2:a7,0)),< strong=""><index(c2:c7,match(g2,a2:a7,0)),vlookup(g2,a2:f7,4,0))*i2*(1-index(f2:f7,match(g2,b2:b7,0),< font="">
IF(H2>INDEX(D2:D7,MATCH(G2,A2:A7,0)),VLOOKUP(G2,A2:F7,4,0))*I2*
</index(c2:c7,match(g2,a2:a7,0)),vlookup(g2,a2:f7,4,0))*i2*(1-index(f2:f7,match(g2,b2:b7,0),<><index(c2:c7,match(g2,a2:a7,0)),vlookup(g2,a2:f7,4,0))*i2*(1-index(f2:f7,match(g2,b2:b7,0),< font="">(1-INDEX(E2:E7,MATCH(G2,A2:A7,0)))*((1-INDEX(F2:F7,MATCH(G2,A2:A7,0)))))))</index(c2:c7,match(g2,a2:a7,0)),vlookup(g2,a2:f7,4,0))*i2*(1-index(f2:f7,match(g2,b2:b7,0),<></index(c2:c7,match(g2,a2:a7,0)),<><index(b2:b7,match(g2,a2:a7,0)),h2*i2,< strong=""><index(c2:c7,match(g2,a2:a7,0)),< strong="">
</index(c2:c7,match(g2,a2:a7,0)),<></index(b2:b7,match(g2,a2:a7,0)),h2*i2,<><index(b2:b7,match(g2,a2:a7,0)),h2*i2,< strong=""><index(c2:c7,match(g2,a2:a7,0)),< strong="">
I tried to paste the formula, but it only pastes part of it, I do not know why..
Is there a formula that could derive the correct answer, sorry for the formula, I tried to paste it from word numerous times and it for
<index(b2:b7,match(g2,a2:a7,0)),h2*i2,if(h2<index(c2:c7,match(g2,a2:a7,0)),< strong=""><index(b2:b7,match(g2,a2:a7,0)),h2*i2,if(h2<index(c2:c7,match(g2,a2:a7,0)),vlookup(g2,a2:f7,4,0))*i2*(1-index(f2:f7,match(g2,b2:b7,0),if(h2>
</index(b2:b7,match(g2,a2:a7,0)),h2*i2,if(h2<index(c2:c7,match(g2,a2:a7,0)),vlookup(g2,a2:f7,4,0))*i2*(1-index(f2:f7,match(g2,b2:b7,0),if(h2></index(b2:b7,match(g2,a2:a7,0)),h2*i2,if(h2<index(c2:c7,match(g2,a2:a7,0)),<><index(b2:b7,match(g2,a2:a7,0)),h2*i2,if(h2<index(c2:c7,match(g2,a2:a7,0)),< strong="">Hope we can solve this, thank you for taking the time to read this much appreciated. </index(b2:b7,match(g2,a2:a7,0)),h2*i2,if(h2<index(c2:c7,match(g2,a2:a7,0)),<><index(b2:b7,match(g2,a2:a7,0)),h2*i2,if(h2<index(c2:c7,match(g2,a2:a7,0)),< strong="">
<index(b2:b7,match(g2,a2:a7,0)),h2*i2,if(h2<index(c2:c7,match(g2,a2:a7,0)),vlookup(g2,a2:f7,4,0))*i2*(1-index(f2:f7,match(g2,b2:b7,0),if(h2></index(b2:b7,match(g2,a2:a7,0)),h2*i2,if(h2<index(c2:c7,match(g2,a2:a7,0)),vlookup(g2,a2:f7,4,0))*i2*(1-index(f2:f7,match(g2,b2:b7,0),if(h2></index(b2:b7,match(g2,a2:a7,0)),h2*i2,if(h2<index(c2:c7,match(g2,a2:a7,0)),<></index(c2:c7,match(g2,a2:a7,0)),<></index(b2:b7,match(g2,a2:a7,0)),h2*i2,<><index(b2:b7,match(g2,a2:a7,0)),h2*i2,< strong=""><index(c2:c7,match(g2,a2:a7,0)),< strong=""><index(b2:b7,match(g2,a2:a7,0)),h2*i2,if(h2<index(c2:c7,match(g2,a2:a7,0)),< strong=""><index(b2:b7,match(g2,a2:a7,0)),h2*i2,if(h2<index(c2:c7,match(g2,a2:a7,0)),vlookup(g2,a2:f7,4,0))*i2*(1-index(f2:f7,match(g2,b2:b7,0),if(h2>
</index(b2:b7,match(g2,a2:a7,0)),h2*i2,if(h2<index(c2:c7,match(g2,a2:a7,0)),vlookup(g2,a2:f7,4,0))*i2*(1-index(f2:f7,match(g2,b2:b7,0),if(h2></index(b2:b7,match(g2,a2:a7,0)),h2*i2,if(h2<index(c2:c7,match(g2,a2:a7,0)),<></index(c2:c7,match(g2,a2:a7,0)),<></index(b2:b7,match(g2,a2:a7,0)),h2*i2,<></index(c2:c7,match(g2,a2:a7,0)),<index(b2:b7,match(g2,a2:a7,0)),h2*i2,<>
The formula below works up until the second discount, in cell H2, 300 units were purchased which means the buyer is entitled to both discounts on the cost per unit, total cost is derived by 300 x (1-5%) x (1-5%) x $25 = $6,768.75 is the correct answer.
[TABLE="width: 844"]
<tbody>[TR]
[TD="align: center"][/TD]
[TD="align: center"]A[/TD]
[TD="align: center"]B[/TD]
[TD="align: center"]C[/TD]
[TD="align: center"]D[/TD]
[TD="align: center"]E[/TD]
[TD="align: center"]F[/TD]
[TD="align: center"]G[/TD]
[TD="align: center"]H[/TD]
[TD="align: center"]I[/TD]
[TD="align: center"]J[/TD]
[/TR]
[TR]
[TD="align: center"]1[/TD]
[TD="align: center"]Item List[/TD]
[TD="align: center"]Units Discount 1[/TD]
[TD="align: center"]Units Discount 2[/TD]
[TD="align: center"]Wholesale Cost[/TD]
[TD="align: center"]Discount Rate 1[/TD]
[TD="align: center"]Discount Rate 2[/TD]
[TD="align: center"]Item Purchased[/TD]
[TD="align: center"]Total Units[/TD]
[TD="align: center"]Per Unit[/TD]
[TD="align: center"]Total Cost[/TD]
[/TR]
[TR]
[TD="align: center"]2[/TD]
[TD="align: center"]Bellen[/TD]
[TD="align: center"]100[/TD]
[TD="align: center"]250[/TD]
[TD="align: center"]$25[/TD]
[TD="align: center"]5.0%[/TD]
[TD="align: center"]5.0%[/TD]
[TD="align: center"]Bellen[/TD]
[TD="align: center"]300[/TD]
[TD="align: center"] $25[/TD]
[TD="align: center"]#REF![/TD]
[/TR]
[TR]
[TD="align: center"]3[/TD]
[TD="align: center"]Carlota[/TD]
[TD="align: center"]100[/TD]
[TD="align: center"]200[/TD]
[TD="align: center"]$25[/TD]
[TD="align: center"]5.0%[/TD]
[TD="align: center"]5.0%[/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[/TR]
[TR]
[TD="align: center"]4[/TD]
[TD="align: center"]Majestic[/TD]
[TD="align: center"]50[/TD]
[TD="align: center"]150[/TD]
[TD="align: center"]$50[/TD]
[TD="align: center"]10.0%[/TD]
[TD="align: center"]15.0%[/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[/TR]
[TR]
[TD="align: center"]5[/TD]
[TD="align: center"]Sunset[/TD]
[TD="align: center"]75[/TD]
[TD="align: center"]150[/TD]
[TD="align: center"]$75[/TD]
[TD="align: center"]15.0%[/TD]
[TD="align: center"]10.0%[/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[/TR]
[TR]
[TD="align: center"]6[/TD]
[TD="align: center"]Phenolic[/TD]
[TD="align: center"]150[/TD]
[TD="align: center"]250[/TD]
[TD="align: center"]$20[/TD]
[TD="align: center"]5.0%[/TD]
[TD="align: center"]10.0%[/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[/TR]
[TR]
[TD="align: center"]7[/TD]
[TD="align: center"]Zapper[/TD]
[TD="align: center"]200[/TD]
[TD="align: center"]350[/TD]
[TD="align: center"]$15[/TD]
[TD="align: center"]5.0%[/TD]
[TD="align: center"]10.0%[/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[/TR]
</tbody>[/TABLE]
In cell J2, I get a #REF!, now below is the formula I have in cell J2, the highlighted red part is the part that works if units are below 100 and or 250, but once over 250, it does not work, I looked at it on formula evaluator, it goes astray when it starts evaluating the third IF formula. The reason I use this formula is because I want to be able to select any product form the list and type in the units which will then give me the total cost based on the criteria. I think I might have the parenthesis in the wrong place or used one more index function than needed.
IF(H2<INDEX(B2:B7,MATCH(G2,A2:A7,0)),H2*I2<index(b2:b7,match(g2,a2:a7,0)),h2*i2,< strong="">,IF(H2</index(b2:b7,match(g2,a2:a7,0)),h2*i2,<><index(c2:c7,match(g2,a2:a7,0)),<index(b2:b7,match(g2,a2:a7,0)),h2*i2,< strong=""><index(c2:c7,match(g2,a2:a7,0)),< strong=""><index(c2:c7,match(g2,a2:a7,0)),vlookup(g2,a2:f7,4,0))*i2*(1-index(f2:f7,match(g2,b2:b7,0),< font="">
IF(H2>INDEX(D2:D7,MATCH(G2,A2:A7,0)),VLOOKUP(G2,A2:F7,4,0))*I2*
</index(c2:c7,match(g2,a2:a7,0)),vlookup(g2,a2:f7,4,0))*i2*(1-index(f2:f7,match(g2,b2:b7,0),<><index(c2:c7,match(g2,a2:a7,0)),vlookup(g2,a2:f7,4,0))*i2*(1-index(f2:f7,match(g2,b2:b7,0),< font="">(1-INDEX(E2:E7,MATCH(G2,A2:A7,0)))*((1-INDEX(F2:F7,MATCH(G2,A2:A7,0)))))))</index(c2:c7,match(g2,a2:a7,0)),vlookup(g2,a2:f7,4,0))*i2*(1-index(f2:f7,match(g2,b2:b7,0),<></index(c2:c7,match(g2,a2:a7,0)),<><index(b2:b7,match(g2,a2:a7,0)),h2*i2,< strong=""><index(c2:c7,match(g2,a2:a7,0)),< strong="">
</index(c2:c7,match(g2,a2:a7,0)),<></index(b2:b7,match(g2,a2:a7,0)),h2*i2,<><index(b2:b7,match(g2,a2:a7,0)),h2*i2,< strong=""><index(c2:c7,match(g2,a2:a7,0)),< strong="">
I tried to paste the formula, but it only pastes part of it, I do not know why..
Is there a formula that could derive the correct answer, sorry for the formula, I tried to paste it from word numerous times and it for
<index(b2:b7,match(g2,a2:a7,0)),h2*i2,if(h2<index(c2:c7,match(g2,a2:a7,0)),< strong=""><index(b2:b7,match(g2,a2:a7,0)),h2*i2,if(h2<index(c2:c7,match(g2,a2:a7,0)),vlookup(g2,a2:f7,4,0))*i2*(1-index(f2:f7,match(g2,b2:b7,0),if(h2>
</index(b2:b7,match(g2,a2:a7,0)),h2*i2,if(h2<index(c2:c7,match(g2,a2:a7,0)),vlookup(g2,a2:f7,4,0))*i2*(1-index(f2:f7,match(g2,b2:b7,0),if(h2></index(b2:b7,match(g2,a2:a7,0)),h2*i2,if(h2<index(c2:c7,match(g2,a2:a7,0)),<><index(b2:b7,match(g2,a2:a7,0)),h2*i2,if(h2<index(c2:c7,match(g2,a2:a7,0)),< strong="">Hope we can solve this, thank you for taking the time to read this much appreciated. </index(b2:b7,match(g2,a2:a7,0)),h2*i2,if(h2<index(c2:c7,match(g2,a2:a7,0)),<><index(b2:b7,match(g2,a2:a7,0)),h2*i2,if(h2<index(c2:c7,match(g2,a2:a7,0)),< strong="">
<index(b2:b7,match(g2,a2:a7,0)),h2*i2,if(h2<index(c2:c7,match(g2,a2:a7,0)),vlookup(g2,a2:f7,4,0))*i2*(1-index(f2:f7,match(g2,b2:b7,0),if(h2></index(b2:b7,match(g2,a2:a7,0)),h2*i2,if(h2<index(c2:c7,match(g2,a2:a7,0)),vlookup(g2,a2:f7,4,0))*i2*(1-index(f2:f7,match(g2,b2:b7,0),if(h2></index(b2:b7,match(g2,a2:a7,0)),h2*i2,if(h2<index(c2:c7,match(g2,a2:a7,0)),<></index(c2:c7,match(g2,a2:a7,0)),<></index(b2:b7,match(g2,a2:a7,0)),h2*i2,<><index(b2:b7,match(g2,a2:a7,0)),h2*i2,< strong=""><index(c2:c7,match(g2,a2:a7,0)),< strong=""><index(b2:b7,match(g2,a2:a7,0)),h2*i2,if(h2<index(c2:c7,match(g2,a2:a7,0)),< strong=""><index(b2:b7,match(g2,a2:a7,0)),h2*i2,if(h2<index(c2:c7,match(g2,a2:a7,0)),vlookup(g2,a2:f7,4,0))*i2*(1-index(f2:f7,match(g2,b2:b7,0),if(h2>
</index(b2:b7,match(g2,a2:a7,0)),h2*i2,if(h2<index(c2:c7,match(g2,a2:a7,0)),vlookup(g2,a2:f7,4,0))*i2*(1-index(f2:f7,match(g2,b2:b7,0),if(h2></index(b2:b7,match(g2,a2:a7,0)),h2*i2,if(h2<index(c2:c7,match(g2,a2:a7,0)),<></index(c2:c7,match(g2,a2:a7,0)),<></index(b2:b7,match(g2,a2:a7,0)),h2*i2,<></index(c2:c7,match(g2,a2:a7,0)),<index(b2:b7,match(g2,a2:a7,0)),h2*i2,<>