Skip to Content
0

BPC NW - Passing Variable from DM to Script logic

Dec 02, 2016 at 01:19 AM

140

avatar image


Getting below error when i run the pkg - Anything wrong with the DM Advanced Script?

[Message]
--------------------------------------------------------------

RUN_LOGIC:Members invalid On Dimension(TIME)

model: Finance. Package status: ERROR

-----------------------------------------------------------
DM Script :

PROMPT(SELECTINPUT,%SRCTIM%,,"Select src Time:","TIME")
PROMPT(SELECTINPUT,%DESTTIM%,,"Select dest Time:","TIME")
TASK(/CPMB/DEFAULT_FORMULAS_LOGIC,SUSER,%USER%)
TASK(/CPMB/DEFAULT_FORMULAS_LOGIC,SAPPSET,%APPSET%)
TASK(/CPMB/DEFAULT_FORMULAS_LOGIC,SAPP,%APP%)
TASK(/CPMB/DEFAULT_FORMULAS_LOGIC,SELECTION,%SRCTIM%)
TASK(/CPMB/DEFAULT_FORMULAS_LOGIC,SELECTION,%DESTTIM%)


Script Logic:
------------

....
*XDIM_MEMBERSET TIME = $SRCTIM$,$DESTTIM$
....

*WHEN TIME
*IS $SRCTIM$
*WHEN VERSION
*IS ACTUAL
*FOR %DT% = $DESTTIM$
*REC(FACTOR=1,VERSION=P1,AUDIT_ID=E1,TIME = %DT%)
*NEXT
*ENDWHEN
*ENDWHEN


-----


Thanks

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

6 Answers

Best Answer
Vadim Kalinin Dec 02, 2016 at 04:51 PM
0

Ups, sorry, copy error!

PROMPT(COPYMOVEINPUT,%SRCTIM%,%DESTTIM%,"Select the TIME members from to","TIME")
TASK(/CPMB/DEFAULT_FORMULAS_LOGIC,SUSER,%USER%)
TASK(/CPMB/DEFAULT_FORMULAS_LOGIC,SAPPSET,%APPSET%)
TASK(/CPMB/DEFAULT_FORMULAS_LOGIC,SAPP,%APP%)
INFO(%EQU%,=)
INFO(%TAB%,,;)
TASK(/CPMB/DEFAULT_FORMULAS_LOGIC,EQU,%EQU%)
TASK(/CPMB/DEFAULT_FORMULAS_LOGIC,TAB,%TAB%)
TASK(/CPMB/DEFAULT_FORMULAS_LOGIC,MEMBERSELECTION,SRCTIM%EQU%%SRCTIM%%TAB%DESTTIM%EQU%%DESTTIM%)
TASK(/CPMB/DEFAULT_FORMULAS_LOGIC,LOGICFILENAME,COPY_BS.LGF)

Show 1 Share
10 |10000 characters needed characters left characters exceeded

P.S. Script don't need

*WHEN VERSION
*IS ACTUAL

only:

*WHEN TIME
*IS *
*FOR %DT% = $DESTTIM$
*REC(FACTOR=1,VERSION=P1,AUDIT_ID=E1,TIME = %DT%)
*NEXT
*ENDWHEN

0
Gersh Voldman
Dec 02, 2016 at 03:51 AM
1

Hi,

If you need to pass 2 sets on same Dimension then SELECTINPUT is not the best choice. It would be better to use COPYMOVEINPUT or MEMBERFROMTOINPUT.

Try one of those.

Regards,

Gersh

Share
10 |10000 characters needed characters left characters exceeded
Vadim Kalinin Dec 02, 2016 at 07:29 AM
1

In DM advanced script have to be:

PROMPT(SELECTINPUT,%SRCTIM%,,"Select src Time:","TIME")
PROMPT(SELECTINPUT,%DESTTIM%,,"Select dest Time:","TIME")
TASK(/CPMB/DEFAULT_FORMULAS_LOGIC,SUSER,%USER%)
TASK(/CPMB/DEFAULT_FORMULAS_LOGIC,SAPPSET,%APPSET%)
TASK(/CPMB/DEFAULT_FORMULAS_LOGIC,SAPP,%APP%)
INFO(%EQU%,=)
INFO(%TAB%,,;)
CPMB/DEFAULT_FORMULAS_LOGIC,EQU,%EQU%)
CPMB/DEFAULT_FORMULAS_LOGIC,TAB,%TAB%)
TASK(/CPMB/DEFAULT_FORMULAS_LOGIC,MEMBERSELECTION,SRCTIM%EQU%%SRCTIM%%TAB%DESTTIMEQU%%DESTTIM%)

Show 2 Share
10 |10000 characters needed characters left characters exceeded

P.S. And as Gersh recommended the first 2 lines can be replaced by:

PROMPT(COPYMOVEINPUT,%SRCTIM%,%DESTTIM%,"Select the TIME members from to","TIME")

0

P.P.S in the script itself the line:

*XDIM_MEMBERSET TIME = $SRCTIM$,$DESTTIM$

has to be changed to

*XDIM_MEMBERSET TIME = $SRCTIM$

no need to scope destination.

Also allocation can be used to copy values to multiple periods.

0
meghana naidu Dec 02, 2016 at 04:07 PM
0

Thanks Vadim & Gersh..i modified the script but getting a different error now.pls see below...any idea ?

[Message]
--------------------------------------------------------------

RUN_LOGIC:Member "/xxxx/finance/PRIVATEPUBLICATI" not exist

model: finance. Package status: ERROR

Show 1 Share
10 |10000 characters needed characters left characters exceeded

No idea if you will not post your full advanced script and FULL script logic file. Just imaging, I can't see your screen :)

0
meghana naidu Dec 02, 2016 at 04:46 PM
0

Vadim,

Here is the complete logic files

PROMPT(COPYMOVEINPUT,%SRCTIM%,%DESTTIM%,"Select the TIME members from to","TIME")

TASK(/CPMB/DEFAULT_FORMULAS_LOGIC,SUSER,%USER%)
TASK(/CPMB/DEFAULT_FORMULAS_LOGIC,SAPPSET,%APPSET%)
TASK(/CPMB/DEFAULT_FORMULAS_LOGIC,SAPP,%APP%)
INFO(%EQU%,=)
INFO(%TAB%,,;)
CPMB/DEFAULT_FORMULAS_LOGIC,EQU,%EQU%)
CPMB/DEFAULT_FORMULAS_LOGIC,TAB,%TAB%)
TASK(/CPMB/DEFAULT_FORMULAS_LOGIC,MEMBERSELECTION,SRCTIM%EQU%%SRCTIM%%TAB%DESTTIM%EQU%%DESTTIM%)
TASK(/CPMB/DEFAULT_FORMULAS_LOGIC,LOGICFILENAME,COPY_BS.LGF)
------------------------------------------------------------------------

*SELECT(%PC%, "[ID]", "ENTITY", "[FORECAST_DEFAULT]<>'' AND [CALC]='N'")


*XDIM_MEMBERSET ACCOUNT = BAS(CASH)
*XDIM_MEMBERSET AUDIT_ID = BAS(TOT_MGMT)
*XDIM_MEMBERSET CURRENCY = LC
*XDIM_MEMBERSET ENTITY = %PC%
*XDIM_MEMBERSET FLOW = F_CLO
*XDIM_MEMBERSET INTERCO = <ALL>
*XDIM_MEMBERSET SCOPE = S_NONE
*XDIM_MEMBERSET VERSION = ACTUAL
*XDIM_MEMBERSET TIME = $SRCTIM$

*WHEN TIME
*IS $SRCTIM$
*WHEN VERSION
*IS ACTUAL
*FOR %DT% = $DESTTIM$
*REC(FACTOR=1,VERSION=P1,AUDIT_ID=E1,TIME = %DT%)
*NEXT

*ENDWHEN
*ENDWHEN

Share
10 |10000 characters needed characters left characters exceeded
meghana naidu Dec 02, 2016 at 04:51 PM
0

"Task" was missing in 2 statements :) ..

Added that. works fine now.

Thanks Vadim for your help

Show 3 Share
10 |10000 characters needed characters left characters exceeded

Sorry, but where is the "right answer accepted"?

0

Vadim,

how to Accept? I don't know how it shows as accept in my post?

0

After any of my answers you can see:

Comment Share V Accept Alert Moderator

0