Skip to Content
0
Former Member
May 21, 2010 at 03:48 PM

copy key figure to another changing the characteristic

22 Views

Hello,

I'm pretty new to macros and the problem I'm struggeling with is driving me crazy. I wanna create a macro to copy values from one KF to another and change the characteristic in the process. Someone told me that it might not even possible but maybe someone around here knows better.

KF = Key Figure
CH = Characteristic
VAL = Value

The scenario:
+======+======+=============+====
| KF   | CH   | 2012 (e.g.) | ...
+======+======+=============+====
| KF 1 | CH 1 | VAL         | ...
+      +------+-------------+----
|      | CH 2 | 0           | ...
+===========================+====
| KF 2 | CH 1 | 0           | ...
+      +------+-------------+----
|      | CH 2 | 0           | ...
+================================

After running the macro it should be:
+======+======+=============+====
| KF   | CH   | 2012 (e.g.) | ...
+======+======+=============+====
| KF 1 | CH 1 | VAL         | ...
+      +------+-------------+----
|      | CH 2 | 0           | ...
+===========================+====
| KF 2 | CH 1 | 0           | ...
+      +------+-------------+----
|      | CH 2 | VAL         | ...
+================================

To make this happen I think I need to use the agg_level() funktion to make sure that the drilldown is right but I don't know how to switch the object from one characteristic to another or how to put it all together.

Thanks, in advance.

Ben