cancel
Showing results for 
Search instead for 
Did you mean: 

Copy from the property of one dimension to the member of another one in the same model in SAC

satoko_nakayama
Explorer
0 Kudos

Hi experts,

I am currently creating a sales plan within SAC.
The model has the MATERIAL_ID dimension whose property is "profit center" and the PROFIT CENTER dimension.

satoko_nakayama_0-1714122455543.png

  (In order to create a planning PL later, the model design is as described above.)

In the sales plan, the MATERIAL ID is the key and the profit center is counted as "Unassigned."
Then I want to reaccount it to the correct profit centers according to the MATERIAL ID properties.
satoko_nakayama_1-1714122824775.png

I referred to this blog and wrote the following script, but it didn't work.

MENBERSET [d/PROFIT_CENTER]= "#"
MENBERSET [d/MATERIAL_ID]!= "#"

FOREACH [d/PROFIT_CENTER]

DATA()=RESULTLOOKUP([d/PROFIT_CENTER]=[d/MATERIAL_ID].[p/PROFIT_CENTER])

ENDFOR

Could someone tell me how to solve it?


SAP Analytics Cloud for planning 
SAP Analytics Cloud
SAP Analytics Cloud, data modeling 

View Entire Topic
William_Yu
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hi satoko_nakayama

    My suggestions: 

  1. Source data is not having value on Material = "#' , you should adjust the scope definition for Material 
  2. Take profit center from material property syntax should in the DATA() keyword instead of RESULTLOOKUP, it should be: DATA([d/PROFIT_CENTER]=[d/MATERIAL_ID].[p/PROFIT_CENTER])=RESULTLOOKUP()
  3. FOR/EACH seems not needed in this case.

Best regards, William 

 

satoko_nakayama
Explorer
0 Kudos

Hi @William_Yu
Thank you very much for your reply. I will try to correct the script as you suggested. Before that, let me confirm your proposal No.1.

1.Source data is not having value on Material = "#' , you should adjust the scope definition for Material 

Yes, so I wrote the following.
MENBERSET [d/MATERIAL_ID]!= "#"  <---  ! in advanced formula means "exclusion" , I thought. Is my understanding wrong? 

If my thinking is wrong, could you tell me how to fix it in detail?

Best regards, Satoko Nakayama 

William_Yu
Product and Topic Expert
Product and Topic Expert
0 Kudos
Ok, that should be fine. I just missed '!' on first read.
satoko_nakayama
Explorer
0 Kudos

Hi @William_Yu Thank you for your quickly reply.

In the end, I wrote the following script, but I didn't get the expected results.

Can you give me some tips to solve it?

MENBERSET [d/PROFIT_CENTER]= "#"

MENBERSET [d/MATERIAL_ID]!= "#"

DATA([d/PROFIT_CENTER]=[d/MATERIAL_ID].[p/PROFIT_CENTER])=RESULTLOOKUP()

Best Regards, Satoko Nakayama