Variable in FOX - bps

Hello all
i am using variable in BPS  in order to multiply data with the value in the variable.
When i execute the FOX, i get a dump, error.
The error goes " GETWA_NOT_ASSIGNED  - Field Symbol has not yet been assigned"
Can you tell me what can be the problems?
Best
Yuval

Hi,
May be you set up incorrectly a value for the vaiable. This value is not in master data of charater for this variable.
Regards,
Veronika.

Similar Messages

  • How to create an user input variable in SEM-BPS?

    Hi,
    anyone please guide me how to create an user input variable in SEM-BPS? I want to utilized user input variable to udpate characteristic with repost function.
    I tried to create in planning folder, variables right-click create, but the system said 'operation cannot be executed here'...
    please help....
    thanks.

    Hi Bindu,
    would you give me one more help,
    I want to use the variable created for a repost process, how do I achieve that?
    My scenario:
    - There will be a repost function on the planing folder
    - User can select a row or many rows then click the repost function button, then a popup window will appear for user to input the value for the variable
    Is it possible with the scenario? Please advise if I can use standard repost function or should i create a FOX or exit function for this purpose.
    thanks.

  • How to clear variable value in BPS WIB?

    Hi Experts:
                    I want to clear variable value in BPS,and I use this function 'API_SEMBPS_VARIABLE_SET' to set its value to '#'. I got 1 question:
         After I changed this variable manually in IE, the system 'remember' this variable in this program, so the function 'API_SEMBPS_VARIABLE_SET'  didn't work. I checked the table 'UPC_VAR_CHA_ACT' and found there is not any corresponding item for the current user and value.
    Allen

    Hi Bauke,
    Actually I want to do Password Encryption functionality.
    For that I have 1 Java script file.On Java script validation I want to pass password value from client side to server side as,
    <head>
    <script type="text/javascript" language="JavaScript" src="MyJSFile.js">
    function submitForm(element)
    var me = document.getElementById(passwd);
    If(!me)
    alert('Please enter Password);
    else
    Some password logic I will do here.
    </head>
    <f:view>
    <BODY......
    <h:form id="createUserForm">
    <h:commandButton id="save" value="Save" action="saveactionMethod " onclick="submitForm(this)" />
    <h:inputSecrete id="passwd"
    value="#{createUsrFormBean.password}"/>
    </h:form>
    </body>
    </f:view>
    But the Java script code is not working.I mean If I put nothing in password textbox the alert is not firing.
    My code is wrong ?
    Thanks
    Sandip

  • Using variable in fox formula containing several characteristics

    Hi @all,
    is it possible to use a variable in fox containing more than one characteristic? I need to have some additional information for a few 0SEM_POSITs but don't want to create an attribute.
    I've created variable ZSCV25 containing characteristics 0SEM_POSIT and ZSCADVDEL but wasn't able to get any data by using VARI.
    Anybody an idea? Thanks for your help.
    Regards,
    Thomas

    <FONT FACE = "Tahoma", Font Color = "Blue">
    Dear Thomas<br>
    I don't think FOX Formula Variable can contain more than one characteristic value. <br><br>However I can suggest you to try one thing. Create an Exit Variable and in its ABAP Code refer to the master data table of base variable and retrieve the value of its desired attribute. <br><br>For example, let us assume that you have a characteristic 0COMP_CODE and 0COUNTRY is its attribute. Now you want that depending on the value of 0COMP_CODE selected by User in another variable ZCOMP_CODE , 0COUNTRY should be automatically populated in variable ZCOUNTRY. So in this case, please make ZCOUNTRY as an Exit Variable and write ABAP Code for that. In the ABAP Code, get the value of 0COMP_CODE which is entered by User in the other variable ZCOMP_CODE. Then write a select statement in ABAP and retrieve the value of 0COUNTRY from the master data table of 0COMP_CODE where Company Code value is equal to value of variable ZCOMP_CODE.<br>
    I hope I am getting you and you are getting me :-)<br>
    <br>Please let me know in case of any confusion.
    <br><br>
    Hope it helps.<br><br>
    Cheers Abhijit<br>
    </FONT><FONT FACE = "Verdana", Font Color = "Red">
    Removed
    </FONT>

  • How to get the value of a variable in FOX?

    Hi,
    In the FOX program how to get the value of a variable defined in planning area?
    can anyone give me some sample code?
    thanks

    Adding to the last reply,
    you can use VARI(variable) to get the count of the values.
    In the latest version of BPS, you may also use the following new foreach construct:
    FOREACH var IN VARIABLE  variable_id.
    Regards - Ravi

  • Global Variable in Fox Code?

    Via a Parameter Group, I am trying to copy existing records.  During the copy I am trying to replace one characteristic with a sequencial number.  However, during a single execution of the parameter group, the variable is being reset to it's initial value after each new record is created.
    Is there a way to store the value of a variable so sequencial numbering can be achieved?
    Thank you in advance for any suggestions or advice!
    CODING I HAVE TO DATE
        DATA EXISTBPSID   TYPE ZTA_BPSID.
        DATA BPSIDNO      TYPE ZTA_BPSID.
        BPSIDNO  = VARV(BPSTAS2).        [[Set based on entry in intial variable]]
        IF EXISTBPSID = '#'.
           = .
           BPSIDNO = BPSIDNO + 0000000001.       [[FACT: Successfully tested that this will add one to the variable BPSIDNO]]
        ENDIF.
    EXISITING SAMPLE DATA  (Where VARV(BPSTAS2) = 16)
    HIRE....BPS ID........QTY
    AB............#...............2
    CD............#...............1
    EF............#...............4
    EXPECTED RESULTS
    HIRE....BPS ID........QTY
    AB............#...............2
    AB...........16..............2
    CD............#...............1
    CD...........17..............1
    EF............#...............4
    EF...........18..............4
    ACTUAL RESULTS
    HIRE....BPS ID........QTY
    AB............#...............2
    AB...........16..............2
    CD............#...............1
    CD...........16..............1
    EF............#...............4
    EF...........16..............4

    Include characteristic HIRE in your 'fields to be changed' of planning function and in FOX write:
    DATA L_HIRE TYPE HIRE.
    DATA EXISTBPSID TYPE ZTA_BPSID.
    DATA BPSIDNO TYPE ZTA_BPSID.
    BPSIDNO = VARV(BPSTAS2).
    FOREACH L_HIRE.
    IF EXISTBPSID = '#'.
    {L_HIRE,BPSIDNO} = {L_HIRE,EXISTBPSID}.
    BPSIDNO = BPSIDNO + 0000000001.
    ENDIF.
    ENDFOR.

  • IP usinge a variable with FOX forumula

    Hallo Experts,
    we are using IP (not BPS). In a query with a variable (mandatory, single value). We use this variable also in a FOX formula.
    The problem is:
    When using the FOX-Formula the system want to have a value for this variable. But by opening the query the user must give in already a value for this variable (it is the same variable we use in the query definition and in the FOX-Formula).
    What is the reason, that the FOX-Formula does not get the already given in value???
    Thank you very much.... we have not found a solution in OSS...
    Santra

    Santra,
              The behavior of variable value depends where you are running the FOX Function. IF you are running the Fox formula in the planning modeler then there is no surprise you dont have the value for the variable. If you create a Web Application Designer with both the querry and Fox function as pushbutton and then run the WAD and Give the value for the variable and then run the function. You will overide the problem you have now.
              Or under Planning Sequence tab, you have personalization section. give the value for the variable there and run the Fox planning sequence then you will get the variable value. Hope I have Addressed you issue.
    Regards,
    sanjay.

  • Set global variable in FOX formula

    Hi all,
    Does anybody know how to change the value of a global variable inside a FOX formula?.
    I can get its value and assign to a local variable but I would like to set the global value after reading a keyfigure and make some calculations.
    is it possible? maybe with some ABAP function call?
    Thanks for your help!

    Include characteristic HIRE in your 'fields to be changed' of planning function and in FOX write:
    DATA L_HIRE TYPE HIRE.
    DATA EXISTBPSID TYPE ZTA_BPSID.
    DATA BPSIDNO TYPE ZTA_BPSID.
    BPSIDNO = VARV(BPSTAS2).
    FOREACH L_HIRE.
    IF EXISTBPSID = '#'.
    {L_HIRE,BPSIDNO} = {L_HIRE,EXISTBPSID}.
    BPSIDNO = BPSIDNO + 0000000001.
    ENDIF.
    ENDFOR.

  • Variables in FOX formulas in IP

    Hi All!
    I would like to create FOX planning function that will be based on variables.
    So, we have 2 variables AA and BB based on characteristics:
    1. For 0CALMONTH with tech. name AA
    2. For ZPROJECT with tech, name BB
    I have a query, where at the first screen I make a selection for ready-for-input variables AA and BB. Then, at the second screen I execute planning function via button.
    The sense of PF is copy all values of key figure ZKEYFIGURE from ZPROJECT = '0', 0CALMONTH = selected value of variable AA to ZKEYFIGURE of ZPROJECT = selected value of variable BB, 0CALMONTH = selected value of variable AA.
    In master data of characteristic ZPROJECT we have different projects. but 1 is with technical name 0. This is the first master data in table.
    DATA VAR1 TYPE 0CALMONTH.
    DATA VAR2 TYPE ZPROJECT.
    DATA VAR3 TYPE ZPROJECT.
    VAR1= VARV(AA).
    VAR2 = VARV(BB).
    VAR3 = VARI(BB, 1).
    {ZKEYFIGURE, VAR1,VAR2}={ZKEYFIGURE,VAR1,VAR3}.
    After execution I see , that records were read, but 0 generated, 0 changed.
    Maybe someone can advice what I do wrong?

    Firstly,for 0calmonth,the from and to value is same as you are using the selected values of variable AA.
    So no change in the value of 0CALMONTH
    Secondly, in the fox formula,  for zproject, you are using the same variables. Hence the fox formula understands that there is no change in the value.
    Define two variables for zproject, lets say proj1 and proj2.
    Assign proj1 ='0'.
    I have modified your fox code, give a shot with the following code, hopefully you might get the results as you want.
    DATA VAR1 TYPE 0CALMONTH.
    DATA PROJ1 TYPE ZPROJECT.
    DATA PROJ2 TYPE ZPROJECT.
    VAR1= VARV(AA).
    PROJ1 = 0.
    FOR EACH 0CALMONTH IN VARIABLE VAR1.
    PROJ2 = VARI(BB,1).
    {ZKEYFIGURE, PROJ2}={ZKEYFIGURE,PROJ1}.
    Endfor.

  • Using offset for global variables in FOX

    Dear all,
    I'm using global variables (i.e. defined in planning area)in my FOX formulas by using VARV-command.
    I'm doing this for fiscal year, which has default value current year. However I'd like to use this variable also for next year thus creating the following code:
    DATA CURYEAR TYPE 0FISCYEAR.
    DATA NEXTYEAR TYPE 0FISCYEAR.
    CURYEAR = VARV(Z021VA01).
    NEXTYEAR = CURYEAR+1.
    This gives a syntax error. Anabody any idea how I can use offset in the FOX for my variables?
    Thanks in advance!
    Kind regards, Harjan

    Harjan,
    Use TMVL function to get the offsets.
    DATA CURYEAR TYPE 0FISCYEAR.
    DATA NEXTYEAR TYPE 0FISCYEAR.
    CURYEAR = VARV(Z021VA01).
    NEXTYEAR = TMVL(CURYEAR, +1).
    hope it helps.

  • Program to populate variable values in BPS thru file

    Hi All,
    I've layouts in BPS. In my layout my super user has to change Version/ Actual period/forecast period/previous version everymonth. For all the above we are using varibles.
    My requirement is that i need to write code to populate Version from a flat file and in that program only basing on version I need to calculate Actual period/forecast period/previous version. Version is coming from a variable based on 0version and Actual period/forecast period values are based on variable of 0fiscper.
    If anyone has already encountered with such situation pls help me.
    Your help will be highly appreciated.
    Thnaks in advance.
    Isha

    Hello Isha,
    please have a look at the how-to papers "Variable Upload" for loading the version variable and "Variables of Type Exit" for deriving the periods and previous version. http://service.sap.com/bw > SAP BW-BPS > How-to
    Regards,
    Marc
    SAP NetWeaver RIG

  • VARIABLES IN FOX

    Hi Ragav,
    One more Question, how to create variables for charecteristics in fox formula.
    can you give me the syntax. like user have to enter the year for fox formula.

    Hi,
    my scenorio is like this, if user enters 2 account numbers , the amount in first account shoud become -ve and it should add to 2nd account.
    Ex: before  acc1    500
                     acc2   100
           after     acc1  -500
                      acc2   600
    where user have to enter 2 account numbers for which he want to do transactions.

  • Upload variable values to BPS

    Hi All,
    Is there any way to upload values to BPS variables?
    I know we can definetly upload some values to Bex varialbes by flat file (or) personlaization.
    Is the same can be done to BPS variables?
    Any help is greatly appreciated.
    Best Regards,
    Reddy.

    Hi,
    no. If you have static Varible Selection, and one does not want to fill the variable table in BPS0, you can create small program to update these tables:
    UPC_VAR_CHA_ACT
    UPC_VAR_CHA_SEL.
    The question is: which one is faster, manual entry in BPS0 or to create a program to update those tables?
    If you have dynamic selection of a variable (i think this is the most situation happened), it is suggested to use Var exit.
    Best Regards,
    Suan Liono

  • Variable in layout BPS

    Hi all,
    I restricted the characteristics in my layout with a variable user value e without selection in level.
    When I try to start layout I receive the following message:
    Variable ZTDOCV is not a single value. It cannot be used
    I don't want to restrict with a single value, but I need a range.
    How can I do?
    Thank you
    Gianmarco

    Hi
    Planning is always done for unique combination of characteristics master data. It is not possible to post the values for range of values For eg -
    Company code range selected in the variable- 1000 to 3000, in this case you cant post any key figure for company code 1000 to 3000.
    Again it depends on - how you structure the layout. If your characteristics is placed flexibly in row or column structure, then following may happen - eg - company code
    in case of Row
    company code        Amount
    1000                       £ 400
    3000                       £ 600
    in case of column
    Company code     1000            3000
    Amount              £ 400           £ 600
    In of header
    only one value allowed for planning.
    If above is the case in your planning layout, then try to set the variable in BPS0, then it will pick the selected range in the layout.
    hope this helps.
    Regards,
    MJ

  • Using BPS numberic variables in the FOX formula???

    Hi all,
    Can someone tell me how to use one variable (<b>the variable type is 'numberic'</b>) in the FOX formula? Thank you.
    FOX formula example:
    <b>Inventory $= inventory unit * inventory (per unit) * depreciation monthS (<u>this is a numberic variable</u>.</b>
    J.

    Hi John,
       You can use the VARV function to get the value of the numeric variable in FOX.
       Lets say your variable for depreciation months is ZDEPMTS.In your FOX, you
       can say: Inventory $= inventory unit * inventory (per unit) * VARV(ZDEPMTS).
       Hope this helps.
    Cheers
    Srini

Maybe you are looking for