cancel
Showing results for 
Search instead for 
Did you mean: 

APO DP - copying of a key figure while respecting fixed values

Former Member
0 Kudos

I am using APO DP V5.

I have a key figure x in which I have some values which are fixed.

I want to have a macro which sets key figure x to key figure y, but respects any fixed values.

For example, suppose I have values for key figure x as follows:

10, 10, 20 (fixed), 10, 5, 10

And for key figure y, I have values as follows:

12, 12, 12, 15, 15, 15

I want result of key figure x = key figure y to be:

12, 12, 20 (fixed), 15, 15, 15

How can I achieve this result?

Thanks, Bob Austin, Atos Origin

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Bob,

There is a function in Macro that you can use to check if a keyfigure is fixed. The following explains how to use the function:

IS_FIXED()

Syntax

IS_FIXED( Key Figure )

Key Figure: Row, column, or cell element (data source = row attributes)

Description

The IS_FIXED function returns the value 1 if the cell is completely fixed. (The column results from the current step iteration; the row is determined by the Key Figure parameter.) If the cell is not fixed or partially fixed, the return value is 0. The function is not available if the compatibility mode is activated for the macro book.

Now you can write a macro some thing like this..

Step 1: XXX iterations(From Date ; To Date)

If Is Fixed(X Key Figure) = 0

X Keyfigure = Y Keyfigure

End If.

X keyfigure and y Keyfigure are taken from the example you have given for better understanding.

Best Regards

Raghu

Answers (2)

Answers (2)

srinivas_krishnamoorthy
Active Contributor
0 Kudos

While creating a Macro you can always create a result macro based Fixed Portion of a Key Figure. Under row attributes, you can check Fixed Value while developing the macro. (There have been similar queries in this very forum already that you may want to search)

Former Member
0 Kudos

Srinivas,

Thanks for your reply.

But the 'fixed value' option refers to using just the fixed values of the source key figure.

My requirement is to preserve fixed values for a key figure when a different key figure is copied to it.

Regards,

Bob.

srinivas_krishnamoorthy
Active Contributor
0 Kudos

Try to have a condition in the macro. Something like

IF Fixed KF Value <> KF Value, THEN <<COPY STATEMENT>>

So wherever you have a fixed KF value (the cell is fixed) then the copy will not happen and hence the value will get preserved.

Former Member
0 Kudos

Hi Bob,

I'm quite sure this could be done with advanced macros... did you have a try at this ?

Fabrice