4 Replies Latest reply: Sep 13, 2012 5:32 PM by Michael Ellerbeck

Help with Margin % expression, problem with division by zero?

I have two rows of data, Customer, Product, Cost & inputfields of New Price and New Volume

The Bid Sales is calculated by New Price * New Volume

The Bid Cost is Cost/LB * New Volume

The Margin \$ Is Bid Sales - Bid Cost

And the Margin % is Margin \$ / Bid Sales

This appears to work but when I put in values for the first product for the first New Price and New Volume the total for the Margin % shows 10% when I would expect it to be 50%, matching the single row of data's margin.

• Re: Help with Margin % expression, problem with division by zero?

Hi mellerbeck,

sum(CurrentCostPerLB * NewVolume)

Let me know, if this change was helpful for you

Regards,

Ricardo

• Re: Help with Margin % expression, problem with division by zero?

I tried similar things to that, but that isn't quite it. I have to use sum(CurrentCostPerLB * Column(3)) but that still doesn't do the trick?

• Re: Help with Margin % expression, problem with division by zero?

Check my release. It works.

• Re: Help with Margin % expression, problem with division by zero?

Ahh! I see now, thank you! I was trying to use the [New Volume] calculated for the column, instead of going straight to the data that is in the NewVolume...  at least that is how I see it! Anyways, yes it works!