Skip to Content
0
Former Member
Aug 13, 2013 at 05:38 AM

Allocation of Cost

123 Views

Guys,

I am working on a Cost Allocation Model in SAP BPC. I have following Dimensions in these model :-

D_EXPENSES - Account type Dimension (which consist of member IDs such as EXP1(Description : Rent) ,EXP2(Description : Factory Overhead),R_EXP,MHP(Description : Machine Hour per Product),HRS(Description : Hours), QTY(Description : Quantity),MHR(Description : Machine Hours)

X_EXPENSES - User defined Dimension (which consist of member IDs such as TR(Description : Total Rent) , TFOH(Description : Total Factory Overhead), TMHP(Description : Total Machine Hours per Product))

TIME - Time dimension (which consist of member ID:- 2013.TOTAL,2013.01,2013.02,2013.03,2013.04,2013.05,2013.06,2013.07,2013.08,2013.09,2013.10,2013.11,2013.12)

CATEGORY - Entity Dimension (which consist of member ID :- ACTUAL1)

D_PRODUCT- User defined Dimension (which consist of member IDs AC, TV,R_PROD)

CURRENCY - Currency Dimension (which consist of member ID:- INR)

In this model I will be allocating my cost to each of my product. For this purpose , I have used Machine Hours as my Cost Driver.I have used flat files to load the transaction data into the BPC cube.

Following are the formulas for the cost driver

Cost Driver for Cost per product :-

Machine Hours per product = (Quantity of Product/total quantity)*Total Machine Hours

Indirect Expenses per Product = (Machine hours/total Machine Hours)* Total Indirect Expense

I have already calculated the Machine Hours per product and stored the value in X_EXPENSES as TMHP .For the second point that is Indirect Expenses per Product I have written the below mentioned Script :-

*XDIM_MEMBERSET TIME = BAS(2013.TOTAL)

*XDIM_MEMBERSET D_EXPENSES= MHP,EXP1,R_EXP

*XDIM_MEMBERSET D_COMP_CODE = C1000

*XDIM_MEMBERSET RTCURRENCY = INR

*XDIM_MEMBERSET D_CATEGORY = ACTUAL1

*XDIM_MEMBERSET X_EXPENSES = TR,TMHP

*XDIM_MEMBERSET D_PRODUCT = AC,LP,MP,R_PROD

*WHEN D_PRODUCT

*IS AC

*WHEN X_EXPENSES

*IS TR

*REC(EXPRESSION = ([D_EXPENSES].[MHP]/[X_EXPENSES].[TMHP]) * %VALUE%, D_EXPENSES=EXP1)

*ENDWHEN

*ENDWHEN

*COMMIT

While loading the Flat file , I have kept values for D_EXPENSES as R_EXP and D_PRODUCT as R_PROD for loading key figures such as Total Rent and Total Factory Overhead in the Transformation file ,

However the Script is not working in UJKT-Script Logic Tester .It is showing the following log :-

(As Appearing in UJKT)

LOG:

LOG BEGIN TIME:2013-08-12 20:10:59

FILE:\ROOT\WEBFOLDERS\BPC_IN \ADMINAPP\DRIVER_MODEL\TEST.LGF

USER: ATHAKUR1

APPSET: BPC_IN

APPLICATION:DRIVER_MODEL

[INFO] GET_DIM_LIST(): I_APPL_ID="DRIVER_MODEL", #dimensions=8

D_CATEGORY,D_COMP_CODE,D_EXPENSES,D_PRODUCT,MEASURES,RTCURRENCY,TIME,X_EXPENSES

#dim_memberset=7

TIME:2013.01,2013.02,2013.03,2013.04,2013.05,...12 in total.

D_EXPENSES: EXP1,1 in total.

D_COMP_CODE: C1000,1 in total.

RTCURRENCY: INR,1 in total.

D_CATEGORY: ACTUAL1,1 in total.

X_EXPENSES: TMHP,TR,2 in total.

D_PRODUCT:AC,LP,MP,3 in total.

REC :([D_EXPENSES].[MHP]/[X_EXPENSES].[TMHP]) * %VALUE%

CALCULATION BEGIN:

QUERY PROCESSING DATA

QUERY TIME : 2028.00 ms. 0 RECORDS QUERIED OUT.

QUERY REFERENCE DATA

QUERY TIME : 2699.00 ms. 12 RECORDS QUERIED OUT.

CALCULATION TIME IN TOTAL :94.00 ms.

NO RECORDS GENERATED.

CALCULATION END.

ENDWHEN ACCUMULATION: 0 RECORDS ARE GENERATED.

PLEASE HELP

Regards,

Amit