cancel
Showing results for 
Search instead for 
Did you mean: 

Aggregation in Fox Formula

seudunur
Explorer
0 Kudos

Hi,

Here is my requirement:

step1: Load actuals to planning ADSO.

Each GL account has a planning account associated with it. One planning GL can have many actuals GL accounts

step2: In the fox formula, Planning GL needs to be derived from GL master data and load it into the ADSO.

I have written the fox code and the code is validated in DEV multiple times. When the code is moved to QA, If I execute the planning sequence via RSPLAN, data is saved without any issue. When I execute the sequence using AO, BW is going to the Hanging mode and eventually timing out.

Any help is appreciated.

Fox Code:

* constants
V_VERSN = 'ACTUAL'.
V_AREA = 'STD'.
V_AREA_TO = 'DNU_004'.

V_AMT = 0.
V_AMT_U = 0.

FOREACH V_PLGLA IN REFDATA.
V_VERSN_TO = VARV( ZPLVERSN_M_S_V001 ).
V_PLNGLA = ATRV( ZPLPLNGLA, V_PLGLA ).
V_AMT_T = 0.
V_AMT = 0.
V_AMT_U = 0.
V_AMT_UT = 0.

FOREACH V_PLGLA IN REFDATA.

V_PLNGLA1 = ATRV( ZPLPLNGLA, V_PLGLA ).

IF V_PLNGLA1 = V_PLNGLA.
V_AMT_T = { ZAMT_LC, V_AREA, V_PLGLA, V_VERSN }.
V_AMT = V_AMT_T + V_AMT.

V_AMT_UT = { ZUSD_AMT, V_AREA, V_PLGLA, V_VERSN }.
V_AMT_U = V_AMT_UT + V_AMT_U.

ENDIF.

{ ZAMT_LC, V_AREA_TO, V_PLNGLA, V_VERSN_TO } = V_AMT.
{ ZUSD_AMT, V_AREA_TO, V_PLNGLA, V_VERSN_TO } = V_AMT_U.

ENDFOR.
ENDFOR.

Accepted Solutions (0)

Answers (3)

Answers (3)

cornelia_lezoch
Active Contributor
0 Kudos

Hello Sri,

1) why are you not using characteristic relationship type attribute? This sounds to me easier than doing it by fox.

2) if you need the fox - shall fox do only the derivation from the attribute or also the copy?

what in your fox is the actual account?

kind regards

Cornelia

seudunur
Explorer
0 Kudos

This logic is working in Trace mode and not from AO. I think HANA is unable to execute the logic.Any thoughts on how to make it HANA compatible?.

Thanks

seudunur
Explorer
0 Kudos

bpc-fox.jpg

Details of the requirement