cancel
Showing results for 
Search instead for 
Did you mean: 

SAC Calculate after aggregation based on datasphere

Charlielin
Explorer
0 Kudos
411

Dear Expert,

   I am trying to calculate the difference of GP% between current year and last year. But the formula behave kind of weird. Here is our sample data:

Charlielin_1-1726277981742.png

We have calculated the GP% for 2024/08 and 2024/07 in the Analytic Model of Datasphere and it worked just fine(Green). But when it come to SAC story to calculate difference of 2 years, instead of simply minus one from the other, it seem to firstly calculate the difference of each SALES/COST/GP(Orange) and then calculate GP/SALES(Red) which is wrong. What we need is the calculation after aggregation which is just simply 0.42 - 0.37. 

Any suggestion?

We are using live connection from SAC to Datasphere, I've tried to create calculated measures both in the view and analytic model but neither of them worked. 

Appendix 1: Using Exception Aggregation for all fields in the Analytic Model

Charlielin_0-1726451485994.png

 

 

View Entire Topic
Savio_Dmello
Active Participant
0 Kudos

Can you try doing it locally in SAC using Local Formulas in Stories (Table Widgets)

Open your story and select the table widget where you want to apply a local formula.
Click on the table to select it, then access the widget's menu (usually found in the context menu or on the right-hand side).
Add a Local Formula:Go to the "Edit" mode of the table.
Click on the "Add Calculation" option. This is often found in the table's context menu or data panel.
Define the Formula: You will be presented with a formula editor where you can create your local formula. Use the available dimensions, measures, and operators to define your calculation.