CASE ATTR([Report 1 (TED 1)].[Company Code])
WHEN "2316" THEN SUM([Actual Amt])-SUM([Report 1 (TED 1)].[Sales Amount - Budget Rate (C$)])
WHEN "2317" THEN SUM([Actual Amt])-SUM([Report 1 (TED 1)].[Sales Amount - Budget Rate (C$)])
WHEN "2318" THEN SUM([Actual Amt])-SUM([Report 1 (TED 1)].[Sales Amount - Budget Rate (C$)])
ELSE 0 END
Gyuz, Kindly help me. I have a scenario where I need to return difference between 2 columns if the company code is 2316/17/18. I have also attached workbook. Kindly help me.
Thanks,
Ronak
Hello Ronak,
You need to update your formula and let me know if things not work.
IF ATTR([Report 1 (TED 1)].[Company Code])='2316' OR
ATTR([Report 1 (TED 1)].[Company Code])='2317' OR
ATTR([Report 1 (TED 1)].[Company Code])='2318'
THEN
sum([Actual Amt])-sum([Report 1 (TED 1)].[Sales Amount - Budget Rate (C$)])
ELSE 0
END
TG