cancel
Showing results for 
Search instead for 
Did you mean: 

Macro to clear values for a key figure for one product on detail level

Former Member
0 Kudos

Hi Experts

I am looking the key figure at detail level for 5 products and I wanted to put 0 in one of the product.

I am not able to find out the macro which ll help me in doing the same.

Regards

Hitesh

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Hitesh,

You need to be little more clear about the issue, becuase deleting data is varies from DP to SNP keyfigures.

if it is a DP keyfigure, we can write a macro to make the keyfigure as ZERO, and to make the same at detail level you need choose the aggregation when you generate background job for macro, in Mass processing.

and you can create a temp'ry selection profile for the 5 materials to satisfy your requirement and use the same in mass processing

If it is SNP keyfigure, you can not make the same with macro, we have specific transaction codes to delete the live cache orders. if it is SNP order, just let me know what keyfigure it is? if i am able to find the Tcode i can suggest you .

Hope this information will help you

Yarala

Former Member
0 Kudos

Hi Yarala,

This is regarding DP keyfig., Yes I have created selection for 5 and i ll be using the same in background, only thing I did not find macro to delete a perticular characterstic value at KF level.

can you please help me with the macro.

Thanks!

Hitesh

Former Member
0 Kudos

Hi Hitesh,

I guess youneed generate new quick Macro... or you can get from the standard macros a copy of RESET MACRO's

if you wont find, try like

Macro name: Reset macro name

Step: no of iterations you want to make zero ( probly for entire future horizon)

result row: KF that you want to set ZERo =

operator/Function: Calc icon '0'

Hope this structure will help you to dosing the macro. if you are doing it in production directly then will need less efforts, otherwise you need to transport again with all the linked objects PB etc.

Let me know if you need any more help

Yarala

Former Member
0 Kudos

Yarala,

I am using ROW_CLEAR function currently, but I wanted to clear row only for one characterstic on drill down level.

do we have any macro where we can clear KF(product1)= 0

thanks

Former Member
0 Kudos

Sorry Hitesh,

apparently i do not have any ...

But are you not able to find the standard macros from Dev system?

Please ref to 9AEXAMPLE planning book which is made for standard macros, there will be few other plannign books also ... please check

Yarala

Answers (2)

Answers (2)

Former Member
0 Kudos

still working on

Former Member
0 Kudos

Hi Hitesh,

I am not sure to understand what you are trying to do... Could you help me to clarifiy?

1. Do you want to lopad a selection with multiple combination (let's say 5 products) but want only one of them to be deleted?

2. Based on which logic do you want to delete one product and not the other? Based on product name, on a characteristics of the prduct?

Basically in interactive you can use the "drill_down" and "drill_up" function to get to the relevant details.

Then you new to implement your logic, with a condition.

for example if product extra characteristic 1 is equal to 1, delete else do nothing...

For this you can use MATLOC_INC() or MATLOC_INC_C(). (don't forget to maintain the product and locaiton in the planning area settings)

Else you can use IOBJNM_VALUE()... depending what you are trying to do...

I hope it helps... else let me know where did I go wrong!

King regards

Julien

Former Member
0 Kudos

Hi Julien,

I am getting error while drill_down() in backgroun : ABAP/4 processor: GETWA_NOT_ASSIGNED.

Could you please let me know if you experience the same.

I am currently working on version 5.1

thanks

Hitesh

Former Member
0 Kudos

Hi Hitesh

sorry for late answer (holidays)

If you are in background you should not use drill drown (this is for interactive only)

In background you can automaticallly select the aggregation level you want.

So you need 2 differents macros: one for interactive, one for background... The background one is a simpler version of the first.

I hope it helps

Julien

Former Member
0 Kudos

Hi,

Why don't you use transaction /SAPAPO/TSCOPY - Copy/Version Management to copy 0 from one KF to another KF.