cancel
Showing results for 
Search instead for 
Did you mean: 

Copy Key Figure with Disaggregation

Former Member
0 Kudos

Hi experts,

My requirement is to copy KF1 to KF2, where:

- KF1 is defined at a planning level that is more aggregate than the planning level of KF2.

- KF2 would have KF3 as disaggregation key figure.

I want the value from KF1 to be copied to KF2 and disaggregated by KF3

Example:

KF1 is defined at product / location (es: “Statistical Forecast”)

KF2 is defined at product/ location /customer (es: “Forecast disaggregated by Customer”)

KF3 is defined at product/ location /customer (es: “Previous Year sales by Customer”, stored)

My understanding is that Copy Operator could do the copy from KF2 to KF1 (with the prerequisite that the destination KF is stored); but it cannot copy from KF1 to KF2.

Which are the options to cover my requirement?

Thanks,

Patrizia

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Ciao Patrizia,

One point before trying to give you an answer (to the best of my knowledge):

- the copy operator has been designed with the objective to take content from a calculated key figure to a stored one: this with the assumption that the planning level would be the same for source (calculated) and target (stored).

Now, your problem seems to be the math behind it, not the technical ability to copy.

Therefore you need to ask yourself first what allows to K1@PL  to be split to KF2@PLC. Perhaps you will need a key figure obtained by historical average giving you the allocation factor. Under this assumption you may use a design as explained hereafter:

KF1@PL stored

KF1@REQUEST = SUM(KF1@PL)

KF3@PLC stored

KF3@PL = SUM(KF3@PLC)

KF3@REQUEST = SUM(KF3@PLC)

I do not believe you really need a helper key figure, but in this case it would not hurt to have one to make the algorithm more readable, so let's continue

HKF3@PL = KF3@PL

HKF3@REQUEST = SUM(HKF3@PL)

then we can define the coefficients:

HCOEFF@PLC = IF ( HKF3@PL > 0, KF3@PLC/HKF3@PL, 0)

HCOEFF@REQUEST = SUM(HCOEFF@PLC)

and finally your split KF2@PLC would be

KF2@PLC = KF1@PL*HCOEFF@PLC

KF2@REQUEST = SUM(KF2@PLC)

This should do, or any variation of this would work. In particular you may substitute KF3 with any other distribution and it would work.

But overall, I see no need of the copy operator for this. Unless you need KF2 to be a key figure you need for outbound integration, and there you probably would need to keep a stored version of KF2 (into KF4 so speak).

I am sure you wanted to disaggregate using the disaggregate algorithms of IBP, hence you wanted to put a key figure on aggregate level and see that disaggregated down using the embedded disaggregation function..... but really there is no need.....

( at least that seems to me 🙂 )

I hope this helps.

Ciao

Luca

Former Member
0 Kudos

Dear all,

thank for your quick replay and the help

A lot of good suggestions to try.

@Irmi: I did know some of the constraints of the Copy Operator but I missed the requirement that the source KF does not have UOM or CURR conversion. Althought for my specific requirement all of you described options that do not require the Copy Operator, for other requirements this can be a limitation.

Can you please elaborate the reason of the constraint?

former_member654033
Contributor
0 Kudos

Hi Patrizia,

In case of Copy operator, if source KF having UOM/Currency conversion enabled it copies wrong values to the target key figure.

So whenever we are using COPY operator, we must ensure that source KF should not have UOM/Currency conversion enabled Or we first transfer the value to another KF (Calculated) @ same base planning level without UOM/Currency conversion and then use that KF as source key figure.

There are no such restriction at the target key figure apart from

(1) It should be stored only

(2) It should at the base planning level where system can calculate the values at source key figure.

Thanks

Girish

Irmi_Kuntze
Advisor
Advisor
0 Kudos

Hi Patricia

there are really lots of great idea around here 🙂

Regarding copy operator, I tried with source KF being with conversion, and the result was very confusing. It appeared that values of all potential conversions added up, unless you made a proper selection in the copy job on one UoM only or one currency only

So, I got recommendation to try with an assisting calculated kf that just copies 1:1 on the base planning level from the real source kf to the "interims" kf that would than be the source in the copy operator, but just without the conversion, and it worked well

I am not 100% sure why exactly that happens as the conversion is not done on the base planning level itself, but an extra level. But I can recommend if you have any kind of conversion and have multiple possible entries and get wrong results, just give it a trial

By the way, same recommendation applies for advanced simulation, ABC calculation and stat. FC

All that was in SOP 3, have not tested yet if the issue is still applicable in IBP

Cheers

Irmi


Answers (4)

Answers (4)

Former Member
0 Kudos

Thanks to all of you for a lot of helpful answers ang good information

former_member654033
Contributor
0 Kudos

Hi Patrizia,

Try like this.

These are inputs you have :

KF1 (Statistical Forecast) @ PERPRODLOC

KF3 (Previous Year sales by Customer) @ PERPRODLOCCUST

Calculate using helper to comeup with split factor at lowest level (PERPRODLOCUST)

Step 1 : HELPERKF1 @PERPRODLOC = SUM(KF3@PERPRODLOCCUST)

Step 2 : HELPERKF2@PERPRODLOCCUST = IF(ISNULL("HELPERKF1@PERPRODLOC") OR " HELPERKF1@PERPRODLOC" = 0, 0, "KF3@PERPRODLOCCUST"/"HELPERKF1 @PERPRODLOC"

Final Output Calculation:

KF2 (Forecast disaggregated by Customer) @PERPRODLOCCUST = "KF1@PERPRODLOC*"HELPERKF2@PERPRODLOCCUST

I hope this helps.

Thanks

Girish

former_member654033
Contributor
0 Kudos

Hi Patrizia,

One point I missed in my previous response.

KF3 (Previous Year sales by Customer) @ PERPRODLOCCUST should be in same time bucket in the future where you have values in KF1 (Statistical Forecast) @ PERPRODLOC

So as a pre-requisite you may have to use attribute offset to bring prvious year sales to current year and then you can use this new offset KF in place of your KF2. rest of the calculations will remain same as per my previous reply.

Thanks

Girish

Former Member
0 Kudos

Hi Patrizia,

I had a similar requirement but did not have the split factor then so following are the steps conducted:

KF1 is defined at product (es: “Statistical Forecast”)

Helper KF2 is defined at product/ customer (es: “Statistical Forecast disaggregated by Customer”)

KF3 is defined at product/ customer (es: “Previous Year sales”, stored)

KF4 is defined at product/ customer (es: “Previous Year sales by Customer”, stored) - Disaggregated KF1 by KF3.

Helper KF2 = Calculated the sales contribution % of each customer by product. KF3@PERPRODCUST / KF3@PERPROD

KF4@PERPRODCUST = KF1@PERPROD * Helper KF2@PERPRODCUST

Hope this helps.

Regards,

Aditya G

parag_bakde
Explorer
0 Kudos

You can use the defaulting option from KF2 to KF3. If there is no value in KF3, default value from KF2.

Hope that helps.

Regards,

Parag.

Irmi_Kuntze
Advisor
Advisor
0 Kudos

Dear Patrizia

In case the defaulting would not solve your issue, here would be an alternative:

For usage of copy operator, you have to fullfill some pre-conditions, such as:

- source keyfigure needs to know base planning level of the target keyfigure

- and some more, such as source KF must not have any UoM or currency conversion, you'll probably know anyhow

But you can create a calculated , not stored KF that "disaggregates" down content of KF1 to the base planning level of KF2 by using disaggregation based on split factor calculated with KF3...

1) Create a new KF "KF1DET" . No UoM nor currency conversion, calculated, not stored. Logic described in step 3

2) Create helper KF for the split logic to split KF1DET based on KF3. Calculation of split factor is done on the level of baseplanning-level of KF2

3) Calculate the split in KF1DET, using the helper KF multiplied by KF1

4) Create copy operator with source KF = KF1DET and target = KF2

Wen you execute the copy operator, copy is done on the most detailed level of KF2, but Disaggregation starts already on baseplanning level of KF1 based on content of KF3

For more details on the split factor, compare the very very new (released yesterday) modelling guide "SAP Integrated Business Planning 4.0 FP01 Patch 2" chapter 17.6 "Example: Split Factor Calculation" 

http://help.sap.com/download/ibp/ibp40_model_ref_en.pdf

Hope that helps

Irmi