cancel
Showing results for 
Search instead for 
Did you mean: 

SAP BPC 10MS - PASSING VALUES FROM DM TO SCRIPT LOGIC

Former Member
0 Kudos

Hello SAP BPC Expert,

I have a problem while trying to move a values form the DM to a scrip logic. I’m using SAP BPC 10 MS

In a few words, I need to enter only a year in the DM and then use the YEAR value in the script logic to perform some calculation.

So far this is what I tried:

OPTION A:

In the prompt:

PROMPT(TEXT,%YEAR%,"Select a YEAR",,"")

TASK(Execute formulas,USER,%USER%)

TASK(Execute formulas,Environment,%Environment%)

TASK(Execute formulas,Model,%Model%)

TASK(Execute formulas,LOGICFILE,AGGREGATIONS.LGF)

TASK(Execute formulas,RUNMODE,1)

TASK(Execute formulas,LOGICMODE,1)

TASK(Execute formulas,CHECKLCK,1)

TASK(Execute formulas,FORMULASCRIPT,"*FUNCTION YEAR=%YEAR%")

In the logic:

*XDIM_MEMBERSET CATEGORY = ACTUALS

*XDIM_MEMBERSET TIME = %YEAR%.Q1

Error:

Execute formulasError

Invalid member %2006%.Q1

OPTION B:

In the prompt:

PROMPT(TEXT,%YEAR%,"Select a YEAR",,"")

TASK(Execute formulas,USER,%USER%)

TASK(Execute formulas,Environment,%Environment%)

TASK(Execute formulas,Model,%Model%)

TASK(Execute formulas,LOGICFILE,AGGREGATIONS.LGF)

TASK(Execute formulas,RUNMODE,1)

TASK(Execute formulas,LOGICMODE,1)

TASK(Execute formulas,CHECKLCK,1)

TASK(Execute formulas,SELECTION,%SELECTION%)

TASK(Execute formulas,REPLACEPARAM,YEAR=%YEAR%)

In the logic:

*XDIM_MEMBERSET CATEGORY = ACTUALS

*XDIM_MEMBERSET TIME = %YEAR%.Q1

Error:

Execute formulasError

Invalid selection passed:

%SELECTION%

OPTION C:

In the prompt:

PROMPT(TEXT,%YEAR%,"Select a YEAR",,"")

TASK(Execute formulas,USER,%USER%)

TASK(Execute formulas,Environment,%Environment%)

TASK(Execute formulas,Model,%Model%)

TASK(Execute formulas,LOGICFILE,AGGREGATIONS.LGF)

TASK(Execute formulas,RUNMODE,1)

TASK(Execute formulas,LOGICMODE,1)

TASK(Execute formulas,CHECKLCK,1)

TASK(Execute formulas,REPLACEPARAM,YEAR=%YEAR%)

In the logic:

*XDIM_MEMBERSET CATEGORY = ACTUALS

*XDIM_MEMBERSET TIME = %YEAR%.Q1

Error:

Execute formulasError

Invalid member 2022

Basically what I’m trying to achieve is to select in the DM the year and then in the script logic aggregate the data for %YEAR%.Q1, %YEAR%.Q2, %YEAR%.Q3 = %YEAR%.Q4

In NW this was easy to achieve since by having REPLACEPARAM in the DM Promt + the syntax $YEAR$ in the logic was (in a few words) enoght but now, in the MS version the syntax “$” is been recognize (or I’m doing something wrong.

I will appreciate any help.

Accepted Solutions (1)

Accepted Solutions (1)

cecilia_petersson2
Active Participant
0 Kudos

Hi Luis,

I got this to work in a BPC 10 MS model. Hope it helps!

-----------------------------------

DM package:

(COMBOBOX,%COMBO_VAR%,"Please select a form:",0,D1A,P33)

(Execute formulas,FORMULASCRIPT,*FUNCTION $MYFORM$=%COMBO_VAR%)

Logic scope:

*SELECT(%MY_ACCTS%,"[ID]","O_ACCOUNT","[FORM]= '$MYFORM$'")

*XDIM_MEMBERSET O_ACCOUNT = %MY_ACCTS%

-----------------------------------

/Cecilia

Answers (0)