Skip to Content

Script logic have error

Dear Masters,

I have just create one script logic below:

*XDIM_MEMBERSET RB_CATEGORY=PLAN

// Increase Revenue by the percentage entered by the user

[RB_ACCT].[#REVADJ] = [RB_ACCT].[REVENUE]*($Z_INCREASE_REV$/100)

when I validate and save, I see this errors:

LINE 3 syntax error: " ReferenceError: $$Z_INCREASE_REV$ is not defined

Please tell me : where is I have define this variable?

Thank you for your help

Best Regards

Chinh Pham

Add a comment
10|10000 characters needed characters exceeded

Related questions

4 Answers

  • Posted on Feb 13, 2012 at 07:59 AM

    Hi,

    When you use dynamic variables you will get this error if you validate the script. Please save the logic without validation. Then if the dynamic variable is passed correctly from Data Manager, the script can work just fine.

    http://help.sap.com/saphelp_bpc75_nw/helpdata/en/59/f145f708724b9c86d8a65dd57d5e4f/content.htm

    Hope it helpss...

    regards,

    Raju

    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member Pham Chinh Thi

      Hi Chinh Pham,

      Use the process chain name instead of the process variant in the advanced script of the DM package:

      PROMPT(SELECTINPUT,,,,"%ENTITY_DIM%,%CATEGORY_DIM%,%CURRENCY_DIM%,%TIME_DIM%,%DATASRC_DIM%,RB_CUSTOMER,RB_PRODUCT")

      PROMPT(TEXT,%Z_INCREASE_REV%,"Input Revenue Increase in Percent",)

      INFO(%EQU%,=)

      INFO(%TAB%,;)

      TASK(/CPMB/DEFAULT_FORMULAS_LOGIC,TAB,%TAB%)

      TASK(/CPMB/DEFAULT_FORMULAS_LOGIC,EQU,%EQU%)

      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,%SELECTION%)

      TASK(/CPMB/DEFAULT_FORMULAS_LOGIC,LOGICFILENAME,REVALUE_PLAN.LGF)

      TASK(/CPMB/DEFAULT_FORMULAS_LOGIC,REPLACEPARAM,Z_INCREASE_REV%EQU%%Z_INCREASE_REV%)

      Run this and generate the report again.

      Hope this helps,

      Harini.

  • author's profile photo Former Member
    Former Member
    Posted on Feb 14, 2012 at 05:38 AM

    Hi,

    If you are using these kind of variables, then you must capture the value of this variable though DM package. This variable should be defined in the advanced script of the DM package. Once the user executes the DM package, the user will be prompted to post some value against this variable, and then this value will be passes to the script logic.

    Sometimes, even if you define the variable properly in the advanced script of the DM package, you might get error while validating the script logic. In this case, just ignore the error, and save the script logic. Remember, to use the LGF version of the script in the advanced script of the DM package.

    Hope this helps.

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Feb 15, 2012 at 03:01 PM

    Hi,

    You dont have to modify the process chain.

    Link the DM package to the process chain for running default logic. You need to add the below prompt statement in the advanced script of the DM package:

    PROMPT(TEXT,%<variable_name>%,"<text to be displayed>",)

    Then, in the logicfilename statement, mention the LGF version of your script.

    And then, use a statement like:

    TASK(<task name - the same name as in the above statement>,REPLACEPARAM,<variable name>%EQU%%<variable name>%)

    Hope you got the idea.

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Apr 24, 2012 at 09:47 AM

    Thank you all of you

    My issue was resolved by create script logic and report again.

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.