Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello everyone,
Here is my problem: I have a table for invoices (one line = one shipment with its fare), and then I have one table with the detail of what was sent in this shipment, that I'm using to know for each product in this shipment, how much of the total weight (and therefore total fare) it amounted for.
However, I dont have this detail for every invoice, so in some cases I should just use the main fare as is.
I am trying to do a pivot table with those two formulas, but none of them works.
SUM(If(WeightRatio, WeightRatio * TotalFare, TotalFare))
If(WeightRatio, SUM(WeightRatio * TotalFare), SUM(TotalFare))
How to use the WeightRatio * Total fare when I can find my product in the detailed table (meaning it has a WeightRatio value associated with it), and use TotalFare when I cannot?
Thank you very much!
Etienne
Try this
SUM(If(Not IsNull(WeightRatio), WeightRatio * TotalFare, TotalFare))
Thank you for your reply. I just tried it, but the end result is the same as if I just put
Sum(WeightRatio * TotalFare)