SEM-BPS Variable with exit function

Hi,
this is my problem. I use a variable for period and I increment the variable dinamically in a sequence of execution. When I try to read the variable with a exit function, the function is only called the first time and return ok the value, but the next time the function not called and the value is returned from the buffer (I think this, because always is the same value).
How can I change this? I need to my function return the variable value, because is changed.
Thanks.

Hi,
thanks for replys.
I think the problem occurs after update the patch level to level 15. This is the code of class_constructor in class cl_sem_variable:
method CLASS_CONSTRUCTOR.
data ls_dark type upc_dark2.
select single * from upc_dark2 into ls_dark
   where param = c_param_dark_buffer.
if sy-subrc = 0 and ls_dark-value = 'X'.
    m_buffer = 'X'.
endif.
endmethod.
The flag m_buffer is always X and for that reason my the value of the variable is read from the buffer and the exit function for read variable isn't called.
What do yo think about this?
Thanks.

Similar Messages

  • How SEM BPS works with SAP BW

    Hi,
    How SEM BPS works with SAP BW.
    how to save planned in SAP BW.
    how to work with the data in Basic cubes and Transaction cubes.
    what is the relation between these two cubes.
    Thanks,
    cheta.

    hi,
    chk the link for BPS
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/7c85d590-0201-0010-20b5-f9d0aa10c53f
    Can any body send the material for BPS?
    Authorization for BPS
    Ramesh

  • SAP BW SEM-BPS Variables

    Hi All,
    We are upgrading SAP BW SEM-BPS system from 2.0B to 6.O, in this process i need to collect some information as like below from tables,
    like BPS Variables----- UPC_VAR ,
    planning sequence----- UPC_PROFILE_BU
    planning folder(Web)---- BPS_WB
    planning folder(GUI)---UPSPM
    BPS variable exit--UPC_VAR_EXIT
    respectively, but these tables like UPC_VAR,UPC_PROFILE_BU etc are  NOT there in my system ( SAP BW SEM-BPS 2.0B), So can anyone please suggest me alternative table name OR tell me where can I get aobve information like (BPS Variables, Planning Sequence etcc. ).
    Thank you,
    CCC

    Hi,
    I need to collect same information.
    Will you share it.
    Thanks,
    Ajay

  • Change a global variable with a function

    HI ALL!
    I have the following problem...
    I would like to change a global variable with a void function so not like this: variable = function(); .
    What do you suggest?
    Best regards,
    Korcs

    I have the following problem...
    I would like to change a global variable with a void
    function so not like this: variable = function(); .
    What do you suggest?>
    >
    I dont quite understand your question but if your variable is a reference to an object then you can certainly have a method to alter the object that the reference is pointing to and/or the reference itself..
    otherwise your 'function' will have to return the same type as the variable itself in order to do the assignment as you demonstrated, regardless of wether it's C, C# or Java, AFAIK, WIRNM
    HTH

  • Document copy@cell with EXIT function

    hi experts,
    we are doing document created @ cell level in a version and doing version to version copy.
    we are using fox formula for normal data copy,which is working fine,
    we are trying to copy the documents @ cell level from old version to new version after data copy, by using SAP recommended EXIT function.
    we are using UPF_DOC_COPY_EXIT and UPF_DOC_COPY_INIT modules.
    but they are taking lot of time like more than 1 hour.we are terminating the process in between.
    is there any way we can copy the documents.
    thanks in advance,
    sajeevan.

    hello guys,
    for the above EXIT function.if i hard code the values instead of variables in the parameter group, it is executing in less than 30 secs. but the notes are not copied.
    but, if i use variables it is taking lot of time and also not executing.
    any suggestions?
    thanks in advance.
    regards,

  • Figure not updated with exit function

    Hi,
    I have created a function module & have attached to an exit planning function, have create a planning folder that contains input layout from manual planning & this new exit function. but when test the planning folder, figure that have already calculated in the function not refreshed to the input layout, i do debug & the assignment value already correct.
    what should i do to make the assignment in function module get updated in the input layout? the figure used in the fm is in editable mode in the layout.
    Please kindly help.
    Thanks in advance.

    Hi,
    Can you tell how you have added this FM in Planning folder?
    For each function, you can define when the function is executed:
    1. Pushbutton: The user executes the function by clicking on a button.
    2. Execute before layout display: The function is executed before the planning layout is displayed. If the function changes data which is displayed in the layout, the changes are immediately visible in the layout.
    3. Execute before layout change: The function is executed when you exit the planning layout. If the function changes data which is displayed in the layout, the changes are not immediately visible after opening the layout.
    I guess you can use "Execute before Layout Display" mode for your planning function in the planning folder.
    Regards,
    Depti

  • SEM-BPS: Variables of type hierarchy node user exit

    Hi,
    I read the "How to.." document "Variables of Type Exit".
    This document has example for variable type caracteristic.
    I need to use this kind of solution for global variables:
    I have the same variables in several planning areas. I have defined one ‘leading’ area containing the variable that should automatically set/adjust the corresponding variables in the other planning areas.
    I've created a SEM variable of type hierarchy node and with the replacement type user exit. There is a standard function module API_SEMBPS_VARIABLE_GETDETAIL which has to provide the selected hierarchy node in leading area to other areas.
    The function works ideally in test mode, but it doesn't work as the SEM user exit.
    Does anyone have experience in this problem?
    Thanks

    Your function module shall follow the expected interface (required for exit type). Function API_SEMBPS_VARIABLE_GETDETAIL is not for such usage.
    To see an example FM that is fit for a 'user exit' processing for hierarchy node, have a look at FM UPF_VARIABLE_USER_EXIT_HIER. There is inline documentation in the source code that shall help you create your own FM if required.
    cheers,

  • BPS variable type EXIT to expand hierarchy

    Hello,
    Any idea how I can get all elements under a particular node (chosen by the user through a variable) of a hierarchy using a Function module in BPS?
    I have been trying to do this using Function 'RSSH_HIERARCHY_READ' with the following code and parameters (see below)
    Could anyone tell me how to proceed next?
    Thanks in advance
    Points will be assigned
    ""Local Interface:
    *"  IMPORTING
    *"     REFERENCE(I_TYPE) TYPE  UPC_Y_VAR_TYPE
    *"     REFERENCE(I_AREA) TYPE  UPC_Y_AREA
    *"     REFERENCE(I_VARIABLE) TYPE  UPC_Y_VARIABLE
    *"     REFERENCE(IS_HIE_KEY) TYPE  UPC_YS_HIE_KEY
    *"  EXPORTING
    *"     REFERENCE(ET_HIE_NODES) TYPE  UPC_YT_HIESEL
      DATA: BEGIN OF wa_val,
              from TYPE rsleaffrom,
              to   TYPE rsleafto,
            END OF wa_val,
            wa_hierdir    TYPE rshi_s_hiedir,
            wa_hiedirkey  TYPE rshi_s_rshiedirkey,
            wt            LIKE wa_hiedirkey OCCURS 0 WITH HEADER LINE,
            ls_hie_nodes  TYPE upc_ys_hiesel,
            tb_node_val   TYPE rshi_t_hienode,
            tt            LIKE LINE OF tb_node_val,
            tb_interval   TYPE rshi_th_interval.
      SELECT SINGLE hieid objvers FROM /bic/hystopid
             INTO wa_hiedirkey
             WHERE nodename = '00001'.
      CALL FUNCTION 'RSSH_HIERARCHY_READ'
        EXPORTING
          i_rshiedirkey     = wa_hiedirkey
          i_date            = sy-datum
        IMPORTING
          e_rshiedir        = wa_hierdir
          e_t_rsnodes       = tb_node_val
          e_th_rsinterval   = tb_interval
        EXCEPTIONS
          invalid_hierarchy = 1
          name_error        = 2
          iobj_not_found    = 3
          OTHERS            = 4.

    Hi Nicolas,
    It looks like you are trying to program an exit for a hierarchy variable. In there you don't need to return all nodes down to the  leaves. You have to return only the top node(s) that should be selectable.
    Anyway, if you want to read another BPS hiearchy variable, then use the following code:
    FUNCTION z_variable_get_detail_hier.
    *"*"Local interface:
    *"  IMPORTING
    *"     REFERENCE(I_AREA) TYPE  UPC_VAR-AREA
    *"     REFERENCE(I_VARIABLE) TYPE  UPC_VAR-VAR
    *"     REFERENCE(I_BUFFER) TYPE  BOOLE-BOOLE OPTIONAL
    *"  EXPORTING
    *"     REFERENCE(E_SUBRC) TYPE  SY-SUBRC
    *"     REFERENCE(ES_RETURN) TYPE  BAPIRET2
    *"     REFERENCE(E_TYPE) TYPE  UPC_VAR-VARTYPE
    *"     VALUE(ET_HIESEL_ALL) TYPE  UPC_YT_HIESEL
    *"     VALUE(ET_HIESEL) TYPE  UPC_YT_HIESEL
    *"     VALUE(ETO_CHANM) TYPE  UPC_YTO_CHA
      STATICS:
        p_subrc        LIKE sy-subrc,
        ps_return      LIKE bapiret2,
        p_type         LIKE upc_var-vartype,
        pt_hiesel_all  TYPE upc_yt_hiesel,
        pt_hiesel      TYPE upc_yt_hiesel,
        pto_chanm      TYPE upc_yto_cha,
        p_variable     TYPE upc_var-var,
        p_area         TYPE upc_y_area,
        p_first_read   LIKE boole-boole VALUE 'X'.
      DATA:
        lr_variable TYPE REF TO cl_sem_variable.
    * We can't read the values from the buffer if ...
    * - it is the first read
    * - the buffer flag is initial
    * - the stored area or varname differ from imported values.
      IF NOT i_buffer IS INITIAL
        AND p_first_read IS INITIAL
        AND p_area = i_area
        AND p_variable = i_variable.
        e_subrc        = p_subrc.
        es_return      = ps_return.
        et_hiesel_all  = pt_hiesel_all.
        et_hiesel      = pt_hiesel.
        eto_chanm      = pto_chanm.
      ELSE.
    * clear all exporing tables of type reference
        CLEAR: eto_chanm, et_hiesel_all, et_hiesel.
        CALL METHOD cl_sem_variable=>get_instance
          EXPORTING
            i_area       = i_area
            i_variable   = i_variable
          RECEIVING
            rr_variable  = lr_variable
          EXCEPTIONS
            not_existing = 1
            OTHERS       = 2.
        IF sy-subrc <> 0.
          e_subrc = 4.
          CALL FUNCTION 'BALW_BAPIRETURN_GET2'
            EXPORTING
              type   = sy-msgty
              cl     = sy-msgid
              number = sy-msgno
              par1   = sy-msgv1
              par2   = sy-msgv2
              par3   = sy-msgv3
              par4   = sy-msgv4
            IMPORTING
              return = es_return.
          EXIT.
        ENDIF.
    * read details of variable
        CALL METHOD lr_variable->get_attributes
          IMPORTING
            e_type    = e_type
            eto_chanm = eto_chanm.
    * read restricted values
        CALL METHOD lr_variable->get_hie_nodes
          EXPORTING
            i_user     = sy-uname
            i_restrict = 'X'
          RECEIVING
            rt_value   = et_hiesel
          EXCEPTIONS
            error      = 1
            OTHERS     = 2.
        IF sy-subrc <> 0.
          e_subrc = 4.
          CALL FUNCTION 'BALW_BAPIRETURN_GET2'
            EXPORTING
              type   = sy-msgty
              cl     = sy-msgid
              number = sy-msgno
              par1   = sy-msgv1
              par2   = sy-msgv2
              par3   = sy-msgv3
              par4   = sy-msgv4
            IMPORTING
              return = es_return.
          EXIT.
        ENDIF.
    * read all values
        CALL METHOD lr_variable->get_hie_nodes
          EXPORTING
            i_user     = sy-uname
            i_restrict = ' '
          RECEIVING
            rt_value   = et_hiesel_all
          EXCEPTIONS
            error      = 1
            OTHERS     = 2.
        IF sy-subrc <> 0.
          e_subrc = 4.
          CALL FUNCTION 'BALW_BAPIRETURN_GET2'
            EXPORTING
              type   = sy-msgty
              cl     = sy-msgid
              number = sy-msgno
              par1   = sy-msgv1
              par2   = sy-msgv2
              par3   = sy-msgv3
              par4   = sy-msgv4
            IMPORTING
              return = es_return.
          EXIT.
        ENDIF.
    * -- no error occured => store results to buffer
        CLEAR p_first_read.
        p_area         = i_area.
        p_variable     = i_variable.
        p_subrc        = e_subrc.
        ps_return      = es_return.
        pt_hiesel_all  = et_hiesel_all.
        pt_hiesel      = et_hiesel.
        pto_chanm      = eto_chanm.
      ENDIF.
    ENDFUNCTION.
    Regards,
    Marc
    SAP NetWeaver RIG

  • SEM BPS Variable

    I have created a BPS input screen for users to enter data that will end up in a transactional InfoCube.  I've created the Planning Area, levels, etc and it all works fine.  When I am in BPS0, in the layout, I have fiscal week in the header area.  So when I execute the planning screen, I have a popup box that ask what fiscal week I want to enter for.  What I want and have done is to create a variable that looks at the system data and determines our fiscal week.  I put this function module (date_to_period_convert)in the planning area and when I execute it in test mode, it returns the fiscal week.  However, when I try to have this function module populate the fiscal week field on execution, I get nothing. 
    Again, I am just trying to pre-populate a date field based on the system date.
    Thanks for any help you can offer.

    Hello Keith,
    Could you please verify if I get your problem right:
    You have created a variable type User exit. When testing (in se37) the function module used in the exit returns the proper week. Now you use the variable in a planning level. In this planning level you have a layout and the calendar week is in the header of the layout. When executing the layout the calendar week is not filled. Is that your set up?
    Best regards,
    Gerd Schoeffl,
    SAP NetWeaver RIG BI

  • What can i replace this bind variable with in function?

    Hello
    I am creating a report showing training attended by employees. I have written a function to do the following:
    Parameters 1 - 4 is hard coded for a reason. So we dont worry about them.
    5th parameter: :START_DATE represents the date training started
    6th parameter: :END_DATE represents the date training ended.
    These date parameters are correctly used inside the select statement that the function is built upon. So don't worry that my date parameters are correct/incorrect.
    The focus should be on how you use bind variables inside Discoverer Admin. The select at the bottom runs perfectly in Toad and it allows you to use the date parameters as bind variables. But it does not allow it in Discoverer Admin
    The problem is with Parameter 5 and 6. I dont want to hard code the dates as i want the user to be able to enter his own date parameters.
    Discoverer Admin gives an error is i want to use :START_DATE and :END_DATE as parameters
    Does anyone have a solution for my problem.
    This is what the code looks like.
    SELECT apps.xxhr_fsc_training_info.xxhr_fsc_training ('A', '02','M', 'N',:START_DATE, :END_DATE)category_A_training
    , apps.xxhr_fsc_training_info.xxhr_fsc_training ('B', '02','M', 'N',:START_DATE, :END_DATE)category_B_training
    , apps.xxhr_fsc_training_info.xxhr_fsc_training ('C', '02','M', 'N',:START_DATE, :END_DATE)category_C_training
    , apps.xxhr_fsc_training_info.xxhr_fsc_training ('D', '02','M', 'N',:START_DATE, :END_DATE)category_D_training
    , apps.xxhr_fsc_training_info.xxhr_fsc_training ('E', '02','M', 'N',:START_DATE, :END_DATE)category_E_training
    , apps.xxhr_fsc_training_info.xxhr_fsc_training ('F', '02','M', 'N',:START_DATE, :END_DATE)category_F_training
    , apps.xxhr_fsc_training_info.xxhr_fsc_training ('G', '02','M', 'N',:START_DATE, :END_DATE)category_G_training
    from dual
    Edited by: iandekoker on Jun 8, 2009 9:34 PM

    Rod
    I have a request. The request is based on various emails written about passing parameters in Discoverer Admin/Desktop. Now if you are experienced and work with set copntext on regular basis then it should be a walk in the park. However if you are new to it like me, then it seems a daunting task. So my request is: Can't you provide us with an example of how to complete the whole process from begin to end using an actual example? I will kick off the process and maybe you can add where i left something out?
    Example:
    SELECT ENAME, HIRE_DATE
    FROM EMP
    WHERE HIRE_DATE = :IDATE;
    We want to run this select statement in Discoverer Admin, but Admin does not like the :IDATE bind variable. So now we are gonna use SET CONTEXT to find a solution to our problem.
    Step1:
    First we have to create a context namespace in the database for the Discoverer contexts. Here is the code to create the context. It is okay to also named your function EUL_DISCO as this name would work perfectly for almost everyone. Best is to do all of this in the Apps schema. Copy and paste this code in Toad and F9 it. It should compile successfully
    CREATE OR REPLACE CONTEXT eul_disco
    USING apps.eul_disco;
    Step 2:
    Now you need to create a package to enable you to set and retrieve contexts from in Discoverer. Here is the code to create the package and package body. Just copy and paste the code into Toad and F9 (execute) it to create the package.
    --Package Spec
    CREATE OR REPLACE PACKAGE eul_disco AS
    FUNCTION set_context(p_name VARCHAR2, p_value VARCHAR2) RETURN VARCHAR2;
    FUNCTION show_context(p_name VARCHAR2) RETURN VARCHAR2;
    END eul_disco;
    --Package Body
    CREATE OR REPLACE PACKAGE BODY eul_disco IS
    FUNCTION set_context(p_name VARCHAR2, p_value VARCHAR2)
    RETURN VARCHAR2 AS
    BEGIN
    dbms_session.set_context('EUL_DISCO', p_name, p_value);
    RETURN p_value;
    END set_context;
    FUNCTION show_context(p_name VARCHAR2)
    RETURN VARCHAR2 IS
    BEGIN
    RETURN SYS_CONTEXT('EUL_DISCO', p_name);
    END show_context;
    END eul_disco;
    Step3:
    Once you have created this package successfully you need to log into Discoverer Admin. Then use the menu to navigate to Tools > Register PL/SQL Function. A window called 'PL/SQL Functions' will appear. Select the 'Import...' button. A new window called 'Import PL/SQL functions' will appear. Scroll down until you see set_context function. Once you found it click OK to import it to End User Layer. Do the same to import show_context function. Remember there are two functions and you need to import them both. When you are done, click 'Apply' button. Then click 'OK' button. You can double check to make sure your functions have been imported. Just nagivate to Tools > Register PL/SQL function again. When the window 'PL/SQL Functions' appears your function(s) should be in the list on the left hand site. Scroll down untill you find them.
    Step4:
    Now it is time to set your session parameters in a separate worksheet inside Discovere Desktop from your main reports. The following steps show you how to create a worksheet to define an effective date parameter. The parameter worksheet should be based on a folder that always returns exactly one row.
    Log into Discoverer Admin. Open the Business Area you want to use. Then create "New Custom Folder..."
    Copy and paste this code (select sydate from dual) inside the New Custom Folder and validate the code. Also rename your folder to 'Set Context Folder'
    Step 5
    Next log into Discoverer Desktop and choose 'Create New Workbook'. Then choose table layout option. In the available list choose 'Set Context Folder'. When you have highlighted 'Set Context Folder' click on '>' button. Then click then 'Finish' button. Once the workbook is created you will see 1 column called Sysdate and a row with today's date in it. Save this workbook and name this workbook XYZ. You might even rename the sheet to QWE.
    Step 6:
    Still in Desktop working on XYZ workbook on QWE sheet, click on Tools > Parameters > New. In the 'Name' field enter START_DATE. Next leave 'Create condition with operator' box unticked. Next in 'Prompt' field enter START_DATE. In 'Description' field enter START_DATE. In 'Default' field enter NULL. Click OK button when you are done.
    Step 7:
    Still in Desktop working on XYZ workbook on QWE sheet, click on Tools > Calculation > New. Click on 'Functions' radio button. Then click on 'Database' folder to expand it. Scroll down till you see 'Set Context' function in the list. Select it and click 'paste >>' button. It will now show: SET_CONTEXT(P_NAME, P_VALUE). Now you need to replace the two parameters (P_NAME, P_VALUE) of the function. Replace P_NAME with 'START_DATE'. When you are done click on Items radio button. Then click on the Parameters folder and select Start_Date.
    When you are done it should look like this: SET_CONTEXT('START_DATE',TO_CHAR(:START_DATE))
    You might want to rename this calculation to START_DATE
    Ps. If you need to create two date parameters START_DATE and END_DATE then you repeat step 7 cause you need one more calculation.
    Just replace START_DATE with END_DATE. You also might want to call this second calculation END_DATE. Thus when you are done you will have 2 calculations:
    SET_CONTEXT('START_DATE',TO_CHAR(:START_DATE))
    SET_CONTEXT('END_DATE',TO_CHAR(:END_DATE))
    This is useful when you want date parameters similar to: 'where date between :Start_date and :End_date'
    Step 8:
    When you now run the XYZ workbook (QWE sheet) it will prompt you for an START_DATE. Enter 10-Jun-2009 (make sure the format you enter the date is similar to the format you have set up in discoverer). Now your XYZ workbook have 2 columns. First column is still called Sysdate with today's date. The second column is called START_DATE with 10-JUN-2009 in it.
    Step 9:
    Now you want to remove the 'SELECT SYSDATE FROM DUAL' data stored in 'SET CONTEXT FOLDER' from your XYZ workbook (QWE sheet) as you no longer need that. Still working with Desktop inside XYZ workbook on QWE sheet > click on Sheet menu option > then Edit Sheet option. On the Select Items tab click on 'Set Context Folder' and click < button to remove the folder from workbook XYZ. Click OK when done and run the workbook XYZ (sheet QWE) again. Now the workbook XYZ (sheet QWE) should only have one column called START_DATE and 10-Jun-2009 as the only row.
    Step 10:
    Rob you might want to come in here. It is also useful to create another calculation retrieving the value of the parameter, so that the value entered for the parameter can be seen when the workbook is run. Please give step by step instruction to complete this process
    Step 11:
    Still remember your initial problem where we wanted to use :IDATE in Discoverer Admin folder, but Discoverer Admin did not like the :IDATE syntax?
    SELECT ENAME, HIRE_DATE
    FROM EMP
    WHERE HIRE_DATE = :IDATE;
    Solution:
    Well now you just replace :IDATE with TO_DATE(SYS_CONTEXT('EUL_DISCO','START_DATE'))
    Log into Discoverer Admin. Open your Business Area. Then create 'New Custom Folder..'.
    Copy the code below and paste it into the new custom folder.
    Then validate the code.
    Rename the new custom folder to 'Solution'
    --copy and paste this code into folder 'Solution'
    SELECT ENAME, HIRE_DATE
    FROM EMP
    WHERE HIRE_DATE = TO_DATE(SYS_CONTEXT('EUL_DISCO','START_DATE'))
    note: 'EUL_DISCO' is the name of the context and package you created in step1
    : 'START_DATE' is the name of the calculation you did in step7
    Then log onto Discoverer Desktop > open your workbook XYZ > open sheet QWE.
    Click on Menu item called Sheet > New Sheet > choose Table layout > click next > scroll down available folders till you find SQL folder with then name 'Solution'. Select 'Solution' folder and click > then click Finish.
    The folder named 'Solution' will be used to populate the newly created sheet with data. You might want to rename the newly created sheet to 'Finally'.
    At this point workbook XYZ should have 2 sheets (QWE and Finally).
    Sheet 'QWE' contains the parameter and nothing else.
    Sheet 'Finally' displays the code found in folder 'Solution'
    First you run sheet QWE to set parameter. When prompt for a date enter '10-JUN-2009'. Click OK button.
    Then click on sheet 'Finally' to allow the parameter to take effect and do its job. You will see that only data true of 10-JUN-2009 are displayed
    Notes:
    This is a very simple example. But if you work thru this example, then you will get the concept behind the idea and would you be able to satisfy your own need.

  • SEM-BPS Variable buffer clearing issue

    Hello experts,
    I have a situation where my user wants to use BPS functionality to perform direct data entry and validations. I know it's not standard, but that's not the point.
    How do I clear the variables buffer so that each time the user enters the plan layout they are requested to enter fresh variables to determine the selection combinations?
    Is there a function module?
    What tables store this info?
    Any suggestions will be appreciated. Thanks!

    I guess I'll answer my own question.
    There are two tables I've found that holds variables they are as follows:
    UPC_VAR_CHA_SEL - Variables - Selections
    UPC_VAR_CHA_ACT - Variables - Restricted Values
    A function module was created to read these tables and delete the values, based on the userid, hence causing a refresh.
    The function module needed to be executed in the planning folder on 'save'.
    This has worked fine.

  • SEM-BPS Distribution with Reference Data

    All,
    Our planning design is such that our plan values are in one cube and our actuals are in another.  We use a mult-planning area to tie the two together.
    One of our requirements is distribute planning values from one cost center to other cost centers, but to use the actual data on the receiving cost centers as the base.  I have been able to accomplish this with the allocation function, but we need to retain the sender values.  I have been trying to use the Distribute by Reference Data from Sender to Recipient planning function, but it's not reading the reference data correctly.
    Does anybody have some insight into this function?
    Thanks
    Kory

    Hi Mary,
    Thanks for the reply.  I had ran it in trace mode and the message was that there was not any reference data; and maybe this is where I'm misunderstanding this planning function.
    Here's the scenario:  I have a cost center and a cost element and want to allocate it to another cost center.  The reference characteristic from the actuals cube that I'm using is cost element.  For example, cost center 4720001 and cost element 990039 have $100 in the planning cube.  I want to distribute this amount to cost centers 4720002 and 4720003, but using cost element 990014 as the reference data from the actuals cube.  Cost centers 4720002 and 4720003 have $200 and $500 posted to cost element 990014, respectively.  So I'm expecting 4720002 to receive $28.57 and 4720003 to receive $71.43.  When I run the function, I get a message for the receiving records stating that no reference data exists.  I have created this using the allocation planning function with success, but we also need to retain the sender values and the allocation function does not do this.
    Any further insight you have is much apreciated.
    Thanks
    Kory

  • How to access BPS variables in ABAP Exit Function

    Hi Experts,
    I am using a Exit Function. My BPS variables contain multiple values. I want to trasfer then (may be directly read) to an internal table from where I can loop over then.
    Could you please suggest me the code for this?
    Points will be awarded.
    Thanks in advance,
    Shiwesh

    Did you try using the FMs API_SEMBPS_VARIABLE_GETDETAIL or Z_VARIABLE_GET_DETAIL for this?

  • BW-BPS and Exit function on a variable

    I have a variable that has 2 characteristics.  I have an exit function to fill the variable.  I am getting a short dump when executing the functional module.  Here is the code I am using and the error message.  Any help would be appreciated.
      ls_varsel-seqno = '0000'.
      ls_varsel-chanm = 'ZLOCBRAND'.
      ls_varsel-sign = 'I'.
      ls_varsel-opt = 'EQ'.
      LOOP AT lt_chavl INTO ls_chavl.
        if ls_chavl-/BIC/ZLOCBRAND <> ''.
          ls_varsel-seqno = ls_varsel-seqno + 1.
          ls_varsel-low = ls_chavl-/BIC/ZLOCBRAND.
          APPEND ls_varsel TO eto_charsel.
        endif.
      ENDLOOP.
      ls_varsel-chanm = 'ZBUS_UNIT'.
      ls_varsel-sign = 'I'.
      ls_varsel-opt = 'EQ'.
      LOOP AT lt_chavl INTO ls_chavl.
        if ls_chavl-/BIC/ZBUS_UNIT <> ''.
          ls_varsel-seqno = ls_varsel-seqno + 1.
          ls_varsel-low = ls_chavl-/BIC/ZBUS_UNIT.
          APPEND ls_varsel TO eto_charsel.
        endif.
    ENDLOOP.
    error : ITAB_ILLEGAL_SORT_ORDER
    \CLASS=CL_SEM_VARIABLE\METHOD=GET_VALUE\DATA=RTO_VALUE

    Hi Rich,
    looks like the table is defined as sorted table. Try to replace your two APPEND statements by INSERT ls_varsel INTO TABLE eto_charsel.
    Hope that helps
    Stephan

  • 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.

Maybe you are looking for