cancel
Showing results for 
Search instead for 
Did you mean: 

Require different calculation for the Grand Total(Overall Result) as compared to Sub-Results in SAP bex query designer

Former Member
0 Kudos

HI All,


I require a different calculation for the Grand total(Overall Result row) as compared to the subtotals.

In our case ,We want to calculate Grand total result as the average of sub-total results where as subtotal result performing summation operation.


Scenario:


In the attached report,

-> Observe PO Document with multiple invoices at line item level  which means PO Amt will be same for all the invoices under same  PO document number.

            PO Document            Invoice              PO Amount

                    12345                1                        750

                    12345                2                        750

                    12345                3                        750

                                        Result                      750  (Using exception aggregation)

In order to achieve this  we have used exception aggregation in PO Amount with reference to characteristic 'Reference Key' .(See Result row in yellow colour)


-> Observe Result row in green colour which defines the total PO Amount for particular PO document number(summing of PO amts at Item level).

-> Observe overall result which is summing the amounts in green rows,.


Instead of summing , i need the averages of PO Amounts with respect to all PO document numbers at Overall result level.

                             

Accepted Solutions (0)

Answers (4)

Answers (4)

former_member202718
Active Contributor
0 Kudos

Hi Venkat,

For that particular key fugure,try the calculate Result As options you will get the desired results.

rgds

SVU

yasemin_kilinc
Active Contributor
0 Kudos

Hi Venkat,

Try using PO Amount as a selection where you add invoice as constant selection. Then in calculations tab select calculate result as average.

Hope it gives an idea

Regards

Yasemin..

former_member182470
Active Contributor
0 Kudos

Did you try with simple setting for your PO Amount KF(Calculate Result as Average)? Currently, it is Nothing Defined or Summation has been defined.

anshu_lilhori
Active Contributor
0 Kudos

Try with Exception Aggregation as Average of all values that are not equal to zero--Reference characteristic as Invoice.

Amend your existing exception aggregation with the above one.

See if this works or not.

Regards,

AL