Skip to Content
avatar image
Former Member

Using Auxiliary KFs in Batch Jobs

Hello Folks,

I need help on using Auxiliary KF for Batch pruposes. We have a requirement where I need to perform two types of operations on a KF, and use the two resultants values in another macro. I think I can make use of two auxiliary KFs in macro, but not sure exactly how to do this.

For Example:

AUX KF1 = Mean(KFa),

AUX KF2 = STDV(KFb)

KF 3 = AUXKF1 + 1.25 * AUXKF2

KF3 is to be used in abother condition Macro.

This above macro works fine interactively since we created two KFs in the Planning book for Mean and STDV, But in batch , obviously the values dont get saved, so the resultant KF is not calculated. I am unable to have two Auxiliary rows to be used for Mean and STDV under one Macro step. Can I achive all these in a single Macro ? Should I use two Macros? Can anyone suggest athe best approach

Thanks

Roopa

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • Best Answer
    avatar image
    Former Member
    Jan 14, 2010 at 11:13 AM

    Hello Roopa,

    you can use auxiliar Key Figures in batch jobs, provided you include both the macro which calculates the key figure and the macro which uses it once it is calulated.

    Take as an example the stadard macros used in the SNP planning books (for exmaple PB "SNP94(1)") to calculate days' supply. In order to calculate days' supply, you need first to know the number of working days in each period. You calculate the number of working days in each period with the standard macro "determine Workdays", and save them into an auxiliar KF "Workdays". Then, you use this auxiliar KF in the standard macros "Days' supply".

    The condition to use it in background jobs is that you have to run both macros (in the correct order) in the same batch job, in order for the auxiliar KF to be calculated in the first macro before it is used in the second.

    Hope this helps.

    Kind regards.

    Marcos

    Add comment
    10|10000 characters needed characters exceeded