cancel
Showing results for 
Search instead for 
Did you mean: 

Copy from a member to an attribute of the same dimension on SAP Analytics Cloud (SAC)

andreag412
Explorer
0 Kudos
648

Dear all,

I have to try to copy data from specific members of a dimension to members of the same dimension based on an attribute in the dimension.

The member of the source dimension has the same id as the property.

An explicative table is shown here:

Step 1:

Insert the value in the table only for Product.Segment = X

The dimension is formed like this:

Final result:

I tried writing these codes, but it didn't work. Do you have any ideas?

MEMBERSET [d/Account] = ("GSR_VAT")

//DATA([d/Products]=[d/Products].[p/Segment])=RESULTLOOKUP()

// DATA([d/Products]=[d/Products].[p/Segment]) = RESULTLOOKUP([d/Measures]="FINAL_PERC")

// DATA([d/Measures]="FINAL_PERC", RESULTLOOKUP([d/Products].[p/Segment])) = RESULTLOOKUP([d/Products],[d/Measures]="FINAL_PERC")

Thanks

View Entire Topic
N1kh1l
Active Contributor
0 Kudos

andreagaleandro

() around IF not required. It was not there in my initial post but I copied and it got carried over.

Try the below , I am assuming you have an attribute segment with value "X"

MEMBERSET [d/Account] = "GSR_VAT"
MEMBERSET [d/Measures] = "FINAL_PERC"

FOREACH [d/Products]

IF [d/Products].[p/Segment])!="X" THEN 

DATA()=RESULTLOOKUP([d/Products]=[d/Products].[p/Segment])
ENDIF

ENDFOR<br>

OR, I removed the IF and ENDIF and moved it to member set. Here you can try removing for and end for

MEMBERSET [d/Account] = "GSR_VAT"
MEMBERSET [d/Measures] = "FINAL_PERC"

MEMBERSET [d/Products].[p/Segment])!="X"

FOREACH [d/Products]

DATA()=RESULTLOOKUP([d/Products]=[d/Products].[p/Segment])

ENDFOR

Br.

Nikhil

andreag412
Explorer
0 Kudos

Thanks a lot

Andrea