cancel
Showing results for 
Search instead for 
Did you mean: 

Business rule generate USD Values

Former Member
0 Kudos

Hi Bpc Friends

I can't figure out how some records in BPC has been generated.

I went to see the Audit Data Changes and I found the record that I was looking for and it says Business Rule

I can't understand which Business Rule is being executed.

I went to see the Data Manager and I found that the user load some data running the default logic.

The default logic call the Fxtrans, but the fxtrans it says CURRENCY= GBP

so how Can I understand who is generating these USD records?

*SELECT(%CURRENCYVARIANT%,"ID","RPTCURRENCY","[REPORTING]='Y'")

*FOR %CATS%=%CATEGORY_SET%

*RUN_PROGRAM CURR_CONVERSION
CATEGORY = %CATS%
CURRENCY = GBP //%CURRENCYVARIANT%
TID_RA = %TIME_SET%
RATEENTITY = GLOBAL
OTHER = [ENTITY=%ENTITY_SET%]
*ENDRUN_PROGRAM

*NEXT

Thanks

Michele

Accepted Solutions (0)

Answers (1)

Answers (1)

former_member186338
Active Contributor
0 Kudos

Please provide full default.lgf script!

You can also look on default.lgf log in UJFS for this particular user. Do you know how to find it?

P.S. I suspect that this line is incorrect:

RATEENTITY = GLOBAL

Has to be:

RATEENTITY = Global (Case sencitive)

Former Member
0 Kudos

yes I know that

thanks Vadim I will check the log in BW

Former Member
0 Kudos

Hi Vadim

I have checked the log but there is not trace of USD data

The default logic is that:

*INCLUDE RETAINED_EARNINGS

*INCLUDE FLOW_BALANCING

*INCLUDE FXTRANS

and the three scripts are:

*INCLUDE RETAINED_EARNINGS

*SELECT(%REDSRC%,"[ID]",DATASRC,"DATASRC_TYPE='I'")

*XDIM_MEMBERSET ACCOUNT=BAS(PLAFTUS)
*XDIM_MEMBERSET FLOW=F_CLO
*XDIM_MEMBERSET DATASRC=%REDSRC%
*XDIM_MEMBERSET GROUPS=G_NONE
*XDIM_MEMBERSET RPTCURRENCY=LC,GBP,USD,EUR
*XDIM_MEMBERSET INTCO=BAS(TOTAL_INTERCO)
*XDIM_MEMBERSET COSTCATEGORY= BAS(ALL_COSTCATS)
*XDIM_MEMBERSET PRODUCTGRP=BAS(ALL_PRODGRPS)
//*XDIM_MEMBERSET CHANNEL=<ALL>

*WHEN DATASRC
*IS "MJ_GSALLOC"
*REC(ACCOUNT="RET_EARN_CY",INTCO="I_NONE",COSTCATEGORY="NO_COSTCAT",PRODUCTGRP="NO_PRODGRP")
*REC(ACCOUNT="RET_EARN_CY",INTCO="I_NONE",COSTCATEGORY="NO_COSTCAT",PRODUCTGRP="NO_PRODGRP",FLOW="F_RES")
*ELSE
*WHEN RPTCURRENCY
*IS "LC"
*REC(ACCOUNT="RET_EARN_CY",INTCO="I_NONE",COSTCATEGORY="NO_COSTCAT",PRODUCTGRP="NO_PRODGRP")
*REC(ACCOUNT="RET_EARN_CY",INTCO="I_NONE",COSTCATEGORY="NO_COSTCAT",PRODUCTGRP="NO_PRODGRP",FLOW="F_RES")
*ENDWHEN
*ENDWHEN

*COMMIT

*INCLUDE FLOW_BALANCING

*XDIM_MEMBERSET ACCOUNT=BAS(MNG_BS)
*XDIM_MEMBERSET DATASRC=BAS(CUP_IFRS)
*XDIM_MEMBERSET FLOW=F_ERR,F_NONE
*XDIM_MEMBERSET GROUPS=G_NONE
*XDIM_MEMBERSET RPTCURRENCY=LC

*WHEN DATASRC
*IS <> "MJ_GSALLOC"
*REC(FACTOR=0)
*ENDWHEN

*COMMIT

// Calculate different between F_CLO and F_CLO_CALC and post to F_ERR for flowed accounts and F_NONE for non flowed accounts

*XDIM_MEMBERSET ACCOUNT=BAS(MNG_BS)
*XDIM_MEMBERSET DATASRC=BAS(CUP_IFRS)
*XDIM_MEMBERSET FLOW=BAS(F_CLO_CALC)
*XDIM_ADDMEMBERSET FLOW=F_CLO
*XDIM_MEMBERSET GROUPS=G_NONE
*XDIM_MEMBERSET RPTCURRENCY=LC

*WHEN DATASRC
*IS <> "MJ_GSALLOC"
*WHEN ACCOUNT.FLOWED
*IS Y
*WHEN FLOW
*IS F_CLO
*REC(FLOW=F_ERR)
*IS BAS(F_CLO_CALC)
*REC(FACTOR=-1,FLOW=F_ERR)
*ENDWHEN
*ELSE
*WHEN FLOW
*IS F_CLO
*REC(FLOW=F_NONE)
*IS BAS(F_CLO_CALC)
*REC(FACTOR=-1,FLOW=F_NONE)
*ENDWHEN
*ENDWHEN
*ENDWHEN

*COMMIT

*INCLUDE FXTRANS

*SELECT(%CURRENCYVARIANT%,"ID","RPTCURRENCY","[REPORTING]='Y'")

*FOR %CATS%=%CATEGORY_SET%

*RUN_PROGRAM CURR_CONVERSION
CATEGORY = %CATS%
CURRENCY = GBP //%CURRENCYVARIANT%
TID_RA = %TIME_SET%
RATEENTITY = GLOBAL
OTHER = [ENTITY=%ENTITY_SET%]
*ENDRUN_PROGRAM

*NEXT

Former Member
0 Kudos

Hi Vadim

How can I check that this program (this business rule) doesn't generate data in USD?

Thanks

*RUN_PROGRAM CURR_CONVERSION
CATEGORY = %CATS%
CURRENCY = GBP //%CURRENCYVARIANT%
TID_RA = %TIME_SET%
RATEENTITY = GLOBAL
OTHER = [ENTITY=%ENTITY_SET%]
*ENDRUN_PROGRAM

former_member186338
Active Contributor
0 Kudos

At least the first script wil work with USD...

former_member186338
Active Contributor
0 Kudos

P.S. In general the scripts are strange - the scope of default.lgf (changed values) is not used in the script at all...

Please read:

https://blogs.sap.com/2014/06/09/how-to-write-defaultlgf/

former_member186338
Active Contributor
0 Kudos

This code will not generate USD values!

CURRENCY = GBP

Only LC->GBP will happen

Former Member
0 Kudos

exactly so I don't understand how the usd records are generated

I agree with you about the first script but it will not generate usd records so because the user loads data in LC, how is that possible?

Thanks

former_member186338
Active Contributor

Sorry, but you have to test everything yourself!

Even if user is entering data in LC then in the first script the scope is completely redefined!

*XDIM_MEMBERSET RPTCURRENCY=LC,GBP,USD,EUR

The scripts are written incorrectly, have to be redeveloped!

Former Member
0 Kudos

ok thanks Vadim

former_member186338
Active Contributor

If you want some help with default.lgf you need to clearly specify:

scope1 of send data -> calculation logic -> where to store result

scope2 of send data -> calculation logic -> where to store result

...

Former Member
0 Kudos

thanks Vadim

I haven't written these script logic. The consultant company did the project and I joined after they have finished

former_member186338
Active Contributor

Sorry, but now it's your logic 🙂 And it's incorrect!

Former Member
0 Kudos

thanks for your advices. I will try to improve