on ‎2019 Oct 10 4:13 AM
Hi Experts
In the example shown below, we have two sets of source data and to calculate the logic Total Expenses multiply with Ratios with Product combinations and to post the target with product combination and country

Source Data : 1 Total EXP with the combination of some products having value ex:37000
Source Data : 2 To save the Ratio in BPC. I have taken some dummy members and saved in different scope.
Could you please help me in below logic to call the (source data 2 )[AUDIT].[RATIO] to in to logic which is saved in different scope
*WHEN ACCOUNT
*IS TOTAL EXPENSE
*WHEN PRODUCT
*IS ABC
*IS DEF
*IS GHI
*REC(EXPRESSION =(source data 1) %VALUE%* (source data 2 )[AUDITIDM].[RATIO] = Target members)
*ENDWHEN
*ENDWHEN
Thanks
Kishore V
Help others by sharing your knowledge.
AnswerRequest clarification before answering.
Requirements:
We have 3 products AAAA, BBBB, CCCC (base or parent??)
On the account TOTAL_EXPENSE (parent?) sum of the mentioned 3 products have to be allocated to products like A1_123_PROD (how to select all products like A1_123_PROD???)
Allocation have to be done using account RATIO for each product like A1_123_PROD.
Result of allocation to be stored in account 6701000
All other dimensions have to be described in details!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi vadim.kalinin
After running the script, results are showing zero values.
Above script we have scoped for Source data 1 table.( Total expenses with product data)
How are we calling Source data 2 table ( Ratios are having with different scope members not are equal to Source Data 1)
Can we use lookup in script to call Ratios (source data 2 table)
Thanks
Kishore V
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
"After running the script, results are showing zero values" - sorry, but I am unable to see what you are doing!
How do you run the script?
What is the script text?
What about log?
What data you have?
Please read:
https://blogs.sap.com/2014/01/31/how-to-ask-questions-about-script-logic-issues/
OK, you have 5 Product members. (ex: A1_123,A1_345)
And in ACCOUNT you have:
AMOUNT - original amount
RATIO - ratio stored
RESULT - target result to be saved
Then the script will be:
*WHEN ACCOUNT
*IS AMOUNT
*WHEN PRODUCT
*IS A1_123,A1_345 //list of required products
*REC(EXPRESSION=%VALUE%*[ACCOUNT].[RATIO],ACCOUNT=RESULT)
*ENDWHEN
*ENDWHEN
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
P.S. If you want to run this script using DM package then it can be:
//Scope source data
*XDIM_MEMBERSET ACCOUNT=AMOUNT
*XDIM_MEMBERSET PRODUCT=A1_123,A1_345 //list of required products
*WHEN ACCOUNT
*IS * //already scoped
*REC(EXPRESSION=%VALUE%*[ACCOUNT].[RATIO],ACCOUNT=RESULT)
*ENDWHENMy previous code was for default.lgf
Correct setup has to be:
1. Only single member for Product
2. Ratio - has to be member of account dimension
3. Target has to be different account then source
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
| User | Count |
|---|---|
| 40 | |
| 9 | |
| 4 | |
| 4 | |
| 3 | |
| 2 | |
| 2 | |
| 2 | |
| 2 | |
| 2 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.