on 04-14-2014 3:23 PM
Hi!
I need to write a fox formula copying data from cube A (actuals) to cube B (plan, realtime).
Speciality why standard copy function is not working in this case:
I may have combinations of characteristics in my cube B, which do not exist in cube A, and I want to keep them after copy. The standard copy function is multiplying each line in cube B with -1 before it copies the lines of cube A to cube B. Lines which do not exist in cube A will be lost.
So my copy function should work as follows:
As a result, cube B should look like cube A for all records that exist in cube A PLUS all records in cube B which do not exist in cube A.
Any idea how this can be done using a fox formula?
Thanks in advance
Marco
First Its important to check at what granularity you are changing data.Please ensure when you are copying only Characteristic which will change mark it in fields to be changed.Check using standard function.
Secondly You can achieve the same functionality through FOX by restricting cube B in filter and read Cube A in reference,Compare using IF statement Subset if matches in both A and B then update Keyfigure value.
Third You can also achieve this by writing custom planning function where Cube B data can be read in C_TH_DATA and update C_TH_DATA only based on I_TH_Reference data.
Hope it helps.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Marco,
You can refer to below links for FOX code and standard examples for your reference:
http://help.sap.com/saphelp_nw70ehp2/helpdata/en/47/90d158d4944befe10000000a42189d/content.htm
If you still face any issues feel free to ask.
Thanks
Hi Marco,
never do the "multiply with -1" in your formulas. This is something that seems to happen to you, but it does not.
The aggregation behaviour of the cube does a calculation of a delta record - having a new value of 0 and a data record of maybe 4 it calculates 4 (old record) + (aggregation) -4 (delta record) = 0 (new value).
in a fox you always calculate the new value - the delta will automatically be calculated by the cube.
now in your case you need something like:
if {KF, CubeA} <> 0.
{KF, Cube B} = {KF, CubeA}.
endif.
to make this work, cube A must be included in the filter of your function.
regards
Cornelia
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
83 | |
10 | |
10 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.