dustyjay16
New Member
- Joined
- Mar 17, 2014
- Messages
- 4
I have found out, thanks to you wonderful people, how to use SumProduct formulas. Now I have a new question. What would be the best way to use the sumproduct formula for tiered pricing, if you have several different sets of tiers. For instance what if you have 5 customers and each of them has their own set of tiers. If you had each set of tiers set up on a different tab, how could you then use a formula to calculate the total cost of each transaction based on whichever customer it is. It seems like it would be a vlookup mixed with a sumproduct.[TABLE="width: 192"]
<tbody>[TR]
[TD="class: xl63, width: 64, bgcolor: transparent"]Customer
[/TD]
[TD="class: xl63, width: 64, bgcolor: transparent"]Gallons
[/TD]
[TD="class: xl63, width: 64, bgcolor: transparent"]Total Cost
[/TD]
[/TR]
[TR]
[TD="bgcolor: transparent, align: right"]1
[/TD]
[TD="bgcolor: transparent, align: right"]26
[/TD]
[TD="class: xl64, bgcolor: transparent"]???
[/TD]
[/TR]
[TR]
[TD="bgcolor: transparent, align: right"]2
[/TD]
[TD="bgcolor: transparent, align: right"]22
[/TD]
[TD="bgcolor: transparent"][/TD]
[/TR]
[TR]
[TD="bgcolor: transparent, align: right"]3
[/TD]
[TD="bgcolor: transparent, align: right"]37
[/TD]
[TD="bgcolor: transparent"][/TD]
[/TR]
[TR]
[TD="bgcolor: transparent, align: right"]1
[/TD]
[TD="bgcolor: transparent, align: right"]42
[/TD]
[TD="bgcolor: transparent"][/TD]
[/TR]
[TR]
[TD="bgcolor: transparent, align: right"]2
[/TD]
[TD="bgcolor: transparent, align: right"]33
[/TD]
[TD="bgcolor: transparent"][/TD]
[/TR]
</tbody>[/TABLE]
[TABLE="width: 128"]
<tbody>[TR]
[TD="colspan: 2"]Customer 1 Tiers
[/TD]
[/TR]
[TR]
[TD]0 - 20
[/TD]
[TD]$5 each
[/TD]
[/TR]
[TR]
[TD]> 20
[/TD]
[TD]$3 each
[/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD="colspan: 2"]Customer 2 Tiers
[/TD]
[/TR]
[TR]
[TD]0 - 10
[/TD]
[TD]$5 each
[/TD]
[/TR]
[TR]
[TD]10 - 20
[/TD]
[TD]$4 each
[/TD]
[/TR]
[TR]
[TD]> 20
[/TD]
[TD]$3 each
[/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD="colspan: 2"]Customer 3 Tiers
[/TD]
[/TR]
[TR]
[TD]0 - 10
[/TD]
[TD]$7 each
[/TD]
[/TR]
[TR]
[TD]10 - 30
[/TD]
[TD]$5 each
[/TD]
[/TR]
[TR]
[TD]> 30
[/TD]
[TD]$4 each
[/TD]
[/TR]
</tbody>[/TABLE]
<tbody>[TR]
[TD="class: xl63, width: 64, bgcolor: transparent"]Customer
[/TD]
[TD="class: xl63, width: 64, bgcolor: transparent"]Gallons
[/TD]
[TD="class: xl63, width: 64, bgcolor: transparent"]Total Cost
[/TD]
[/TR]
[TR]
[TD="bgcolor: transparent, align: right"]1
[/TD]
[TD="bgcolor: transparent, align: right"]26
[/TD]
[TD="class: xl64, bgcolor: transparent"]???
[/TD]
[/TR]
[TR]
[TD="bgcolor: transparent, align: right"]2
[/TD]
[TD="bgcolor: transparent, align: right"]22
[/TD]
[TD="bgcolor: transparent"][/TD]
[/TR]
[TR]
[TD="bgcolor: transparent, align: right"]3
[/TD]
[TD="bgcolor: transparent, align: right"]37
[/TD]
[TD="bgcolor: transparent"][/TD]
[/TR]
[TR]
[TD="bgcolor: transparent, align: right"]1
[/TD]
[TD="bgcolor: transparent, align: right"]42
[/TD]
[TD="bgcolor: transparent"][/TD]
[/TR]
[TR]
[TD="bgcolor: transparent, align: right"]2
[/TD]
[TD="bgcolor: transparent, align: right"]33
[/TD]
[TD="bgcolor: transparent"][/TD]
[/TR]
</tbody>[/TABLE]
[TABLE="width: 128"]
<tbody>[TR]
[TD="colspan: 2"]Customer 1 Tiers
[/TD]
[/TR]
[TR]
[TD]0 - 20
[/TD]
[TD]$5 each
[/TD]
[/TR]
[TR]
[TD]> 20
[/TD]
[TD]$3 each
[/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD="colspan: 2"]Customer 2 Tiers
[/TD]
[/TR]
[TR]
[TD]0 - 10
[/TD]
[TD]$5 each
[/TD]
[/TR]
[TR]
[TD]10 - 20
[/TD]
[TD]$4 each
[/TD]
[/TR]
[TR]
[TD]> 20
[/TD]
[TD]$3 each
[/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD="colspan: 2"]Customer 3 Tiers
[/TD]
[/TR]
[TR]
[TD]0 - 10
[/TD]
[TD]$7 each
[/TD]
[/TR]
[TR]
[TD]10 - 30
[/TD]
[TD]$5 each
[/TD]
[/TR]
[TR]
[TD]> 30
[/TD]
[TD]$4 each
[/TD]
[/TR]
</tbody>[/TABLE]