Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello,
I have a situation when we receive one file and it is planned for the future, so numbers are for the whole month. But now in the calculations these numbers are appearing, and I want to restrict this.
My calculation is very simple, like this:
=sum(Sales_Amount)-
sum(Discount_Amount)
Sales are coming for the previous day, but discounts are for whole month. (they are not discounts, it just an example).
Now my bar chart is rising till today, and falling for the rest of the month, because I am substracting 0 - discount.
I know I might use if (sum(Sales_Amount) <> 0 ... But is this the correct solution?
Should I use some set analysis or something?
And How.
Thank you.
The if statement should be fine too... but you can try this
=Sum(Sales_Amount) - Sum({<Date = {"=Sum(Sales_Amount) <> 0"}>}Discount_Amount)
or this
=Sum(Sales_Amount) - Sum({<Sales_Amount = {"*"}>}Discount_Amount)
You could probably use set analysis like:
=sum({<Date={'<=$(=Today())'}>} Sales_Amount)-
sum({<Date={'<=$(=Today())'}>} Discount_Amount)
Can we talk related more about Dataset?
The if statement should be fine too... but you can try this
=Sum(Sales_Amount) - Sum({<Date = {"=Sum(Sales_Amount) <> 0"}>}Discount_Amount)
or this
=Sum(Sales_Amount) - Sum({<Sales_Amount = {"*"}>}Discount_Amount)
1 expression gives Exceeded memory allocation.
2 is doing nothing.
Thank you.
With this solution all my bars dissapear, the week from the beginning of the Year.
Thank you.
Do you have a Date field? I mean what is your chart dimension/s?
Ok, this helps. I am using working day. So after I put this, it seem correct.
Thanks.