Dear All,
I am trying to make a data manager package that calls a script that should copy from one model(app) to another.
In model A(Operational) I have a operational entity dimension called O_Entity in model B(Consolidation) I have a Legal entity dimension called Entity. The dimensions is not shared between the models(apps). Model A have a property(L_Entity) in O_Entity that contains the values of model B's Entities.
I want the end user to be able to trigger this script by selecting Legal entity in model B, that should then call a script in model B that calls a script in model A with runlogic function.
I run for the data manager package in model B with Entity L46736.
I get the following error message:
(Member selection)
Entity: L46736
[Message]
--------------------------------------------------------------
Execute formulasError
Invalid instruction: *FUNCTION $MYENTITY$=[ENTITY] IN (N'L46736')
Please see data manager package and script logic below.
I am open to other solutions if there are any other suggestions on how to handle this.
PROMPT(SELECT,%SRCENTITY%, , "Select Legal Entity",%ENTITY_DIM%)
TASK(Execute formulas,FORMULASCRIPT,*FUNCTION $MYENTITY$=%SRCENTITY%)
TASK(Execute formulas,LOGICFILE,%ModelPath%\..\AdminApp\%Model%\GET_DATA_FROM_OPER.lgf)
TASK(Execute formulas,RUNMODE,1)
TASK(Execute formulas,LOGICMODE,1)
TASK(Execute formulas,CHECKLCK,1)
Script Logic in model B - GET_DATA_FROM_OPER.LGF
---------------------------------------------------------------------------------------------------------
// GET DATA FROM OPERATIONAL
**SELECT(%O_ENTITIES%, "[ID]", "O_ENTITY", "[L_ENTITY]='$MYENTITY$' ")
// STEP 1 - GET DATA
*RUNLOGIC
*APP=OPERATIONAL
*LOGIC=PUSH_TO_CONSOL_LOCAL
*DIMENSION O_ENTITY = %O_ENTITIES%
*ENDRUNLOGIC
Script Logic in model A - PUSH_TO_CONSOL_LOCAL.LGF
---------------------------------------------------------------------------------------------------------
*DESTINATION_APP=CONSOLIDATION
*RENAME_DIM O_AUDITTRAIL=AUDITID
*RENAME_DIM O_ACCOUNT=ACCOUNT
*RENAME_DIM O_ENTITY=ENTITY
*RENAME_DIM O_COST_CENTER = FLOW
*ADD_DIM CONSOSCOPE=G_NONE
*ADD_DIM INTERCO = I_NONE
*SKIP_DIM=O_COUNTERPART
*SKIP_DIM=O_PRODUCT
*SKIP_DIM=XTRANSACTIONCURRENCY
*SKIP_DIM=O_SUB_ENTITY
*XDIM_MEMBER CATEGORY = ACTUAL
*XDIM_MEMBER TIME = 2014.OCT
*XDIM_MEMBERSET O_AUDITTRAIL = INPUT,OUTSIDE_LINE
*XDIM_MEMBER CURRENCY=LC
*XDIM_MEMBERSET O_ACCOUNT=<ALL>
*SELECT(%DESTENTS%, "[ID]", "O_ENTITY", "[L_ENTITY]<>' ' and [L_ENTITY] in (select ID from mbrEntity) and [ID]='%O_ENTITY_SET%' ")
*XDIM_MEMBERSET O_ENTITY=%DESTENTS%
*WHEN O_ACCOUNT.ACCTYPE
*IS AST,LEQ
*REC(O_ACCOUNT=O_ACCOUNT.ACCOUNT,O_ENTITY=O_ENTITY.L_ENTITY,O_AUDITTRAIL=INPUT,O_COST_CENTER=F99)
*ELSE
*REC(O_ACCOUNT=O_ACCOUNT.ACCOUNT,O_ENTITY=O_ENTITY.L_ENTITY,O_AUDITTRAIL=INPUT,O_COST_CENTER=PL99)
*ENDWHEN
*COMMIT
Brgds
Mattias