on 01-09-2018 7:35 PM
Hello All, I am trying to sum couple of accounts and add to existing value in different account & intersection for ex:
A=100, B=50,C=100 D=500 expected result in D = 750 ( Datasource, Account, Reporting line are different)
But after executing following script I am getting 750+500 = 1250 in Account D. It looks like it is not overwriting the new value(750) in destination.
*XDIM_MEMBERSET ACCOUNT=A,B,C
*XDIM_MEMBERSET DATASOURCE=INPUT
*XDIM_MEMBERSET REPORTINLINE=R1
*WHEN REPORTINGLINE
*IS R1
*REC(EXPRESSION=%VALUE% + ([REPORTINGLINE].[R2],[DATASOURCE].[ADJUST],[ACCOUNT].[D]),ACCOUNT=D,DATASOURCE=ADJUST,REPORTINGLINE=R2)
*ENDWHEN
You can use the following script:
//Scope everything
*XDIM_MEMBERSET DATASOURCE=INPUT,ADJUST
*XDIM_MEMBERSET REPORTINLINE=R1,R2
*XDIM_MEMBERSET ACCOUNT=A,B,C,D
*WHEN DATASOURCE
*IS INPUT
*WHEN REPORTINLINE
*IS R1
*WHEN ACCOUNT
*IS A,B,C
*REC(EXPRESSION=%VALUE%,ACCOUNT=D,DATASOURCE=ADJUST,REPORTINGLINE=R2)
*ENDWHEN
*ENDWHEN
*IS ADJUST
*WHEN REPORTINLINE
*IS R2
*WHEN ACCOUNT
*IS D
*REC(EXPRESSION=%VALUE%,ACCOUNT=D,DATASOURCE=ADJUST,REPORTINGLINE=R2)
*ENDWHEN
*ENDWHEN
*ENDWHEN
This script will read input data and aggregate it in D, ADJUST, R2
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks Very much Vadim. I got the expected result.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello Vadim, Here is the sample data.
Account DATSOURCE REPORTINGLINE
A INPUT R1 100
B INPUT R1 50
C INPUT R1 100
D ADJUST R2 500
Expected result:
Account DATSOURCE REPORTINGLINE
D ADJUST R2 750
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Please show the existing data with all dimensions provided. Not only Account!
"Datasource, Account, Reporting line are different" - explain this statement.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
16 | |
3 | |
2 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.