Variable Type EXIT - Locking Transaction Data

Dear all,
I have to use a variable type Exit in the level to identify all cost centers for a planner and his corresponding boss (master data lookup). Now e.g.
the planner has cost center 1 and 2 as possible single values. The boss has cost center 1, 2, 3,and 4 because he also is the boss of an other one.
The result is now that the boss locks all cost centers 1,2,3 and four even if he only plans e.g. the cost center 4. In this way it is not possible for the planner to enter data for 1 or 2 the same time.
Does anybody has an idea to solve this situation or how to lock only the values of the variable that is really in use?
Thanks a lot
Dieter

Hi Dieter,
Refer to Marc's comment in the below post that Planning layouts lock all data
How to avoid SEM-BPS Lock entries
Hence the best option would be to create a different Planning level for Cost center based on the need for planning.
You could also explore the possibility of creating a BEx report wherein the data just needs to be viewed by the boss and not planned.
Hope it helps
Cheers
Anurag
Also take a look at this document to get some more insight into locking in BPS
https://websmp102.sap-ag.de/~sapdownload/011000358700004574572003E/SEMBPSLocking.pdf
Hope you have access to the service marketplace.
Message was edited by: Anurag  Khungar

Similar Messages

  • SEM- VARIABLE TYPE EXIT

    Hi
    We have a planning area where I have various variable that represent the product hierarchy, in particular:
    u2022     Market
    u2022     Brand
    u2022     Family
    The user select the value for any variables and thereu2019s a function module that derives the value of material, the material is another variable type exit.
    The IO material has various attributes that I use in layout, one of these (material group 3) has many value, but I need only two values:
    u2022     PCO
    u2022     STD
    In layout the user has to see only material with PCO, then I create a variable for characteristic material group 3 fixed PCO used in level and layout. Itu2019s ok
    Now I must create another layout in same planning area, where the user has to see both, PCO and STD.
    I created a new level where I donu2019t use the variable for characteristic material group 3, but this variable is fixed PCO, the material derived by FM obviously are only PCO.
    How can I do?
    Thanks in adavance for suggestion
    Edited by: Celi Laura on Apr 28, 2009 3:23 PM

    Hi Dieter,
    Refer to Marc's comment in the below post that Planning layouts lock all data
    How to avoid SEM-BPS Lock entries
    Hence the best option would be to create a different Planning level for Cost center based on the need for planning.
    You could also explore the possibility of creating a BEx report wherein the data just needs to be viewed by the boss and not planned.
    Hope it helps
    Cheers
    Anurag
    Also take a look at this document to get some more insight into locking in BPS
    https://websmp102.sap-ag.de/~sapdownload/011000358700004574572003E/SEMBPSLocking.pdf
    Hope you have access to the service marketplace.
    Message was edited by: Anurag  Khungar

  • Variable type exit with two source variables

    I have a case where I should determine a variable (A) value according to two other variables (B) and (C). That is, e.g.
    - IF (B)=x AND (C)=y THEN (A)=z
    - IF (B)=i AND (C)=j THEN (A)=k
    It seems like I cannot call the user exit with more than one exported variable, the standard call below:
    call function m_user_exit
      exporting
        i_area      = m_area
        i_variable  = m_variable
        i_chanm     = l_chanm
        ito_chanm   = mto_chanm
      importing
        eto_charsel = rto_value
    Any suggestions?
    Regards, Aki

    Thanks to everyone especially to Natarajan,
    Both source variables are type exit, so I did the following:
    A-variable was the “standard source”
    B-variable was determined by function call (source below)
    C-variable then determined by combination of A and B
    I added this simple code in the beginning of “your own logic”  and I had source_var_B as a “B-variable”.
    DATA: source_var_B TYPE upc_yto_charsel.
    call function 'ZDETERMINE_B'
      exporting
        i_area      = 'AREA'
        i_variable  = 'VAR_B'
        i_chanm     = 'CHAR_B'
        ito_chanm   = ito_chanm
      importing
        eto_charsel = source_var_B.
    Do you see any risks or inconsistencies or whatever I should take into account?
    Aki

  • 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

  • Master data Exit & Transaction data exit

    Hi all,
    What is Master data exit  and transaction data exits in BW.
    Where we use them?
    Thanks
    Regards
    Dheepa

    Hi Dheepthi,
    When you want to customize existing datasources at R/3 sides then you can do that with customer exits.
    Suppose if you want to add a column to the existing datasource then you will use append structures (Transaction SBIW-> Edit Data sources - Enhance Datasource) then to fill the column you will write the code in these Exits.
    There are 4 types of Exits available.Function Group (XRSA)
    EXIT_SAPLRSAP_001 Customer Function Call for Supplying Transaction Data
    EXIT_SAPLRSAP_002 Customer Function Call for Supplying Master Data  (Attributes)
    EXIT_SAPLRSAP_003 Customer Function Call for Supplying Text
    EXIT_SAPLRSAP_004 Customer Function Call for Supplying Hierarchies
    As you are aware there 4 types since the datasources in R/3 are predefined to fill the data of BW viz, attributes,Text,Hierarchy and Transaction.
    Check the below forum discussion for more information..
    DataSource Enhancement
    Regs
    Gopi
    Assign point if it helps ..
    Message was edited by: Gopi

  • User Exit variable to determine Month to date

    Hello folks, wondering if someone could please assist with this problem.  I have  a need for a user exit variable that will determine the MTD based on a user input from another variable.  For example, if a user enters 09/15/2009, the exit will know to retrieve information only for the days from 09/012009 - 09/15/2009.  Here is the sample of the code that our ABAP programmer came up with but so far it's not working.  Can someone please have a look at the codes below and let me know what may be the problem?  Thanks.
    in CMOD:
    *&  Include           ZXRSRU01
      DATA: l_sub_name TYPE char30,
            l_f_chk TYPE rs38l_fnam.
      CONSTANTS: lc_sub_prefix TYPE char5 VALUE 'F_BW_'.
      CASE i_step.
        WHEN 3.
          CONCATENATE lc_sub_prefix i_s_rkb1d-infocube INTO l_sub_name.
        WHEN OTHERS.
          CONCATENATE lc_sub_prefix i_vnam INTO l_sub_name.
      ENDCASE.
    *--- this for XXX project. please create programs for
    *--- each individual projects (project).
    *--- variables at STEP 2
      CASE i_vnam.
        WHEN  'BCCMTD'.
          IF l_sub_name IS NOT INITIAL.
            SORT i_t_var_range BY vnam iobjnm.
            PERFORM (l_sub_name) IN PROGRAM    zbw_XXX_exit
                                      USING    i_t_var_range
                                      CHANGING e_t_range.
            CLEAR l_sub_name.
          ENDIF.
        WHEN OTHERS.
      ENDCASE.
    **--- infocubes at STEP 3
      CASE i_s_rkb1d-infocube.
        WHEN 'BSD_M01'.
          IF l_sub_name IS NOT INITIAL.
            SORT i_t_var_range BY vnam iobjnm.
            PERFORM (l_sub_name) IN PROGRAM    zbw_XXX_exit
                                      USING    i_t_var_range
                                      CHANGING e_t_range.
            CLEAR l_sub_name.
          ENDIF.
        WHEN OTHERS.
      ENDCASE.
    Edited by: David on Oct 1, 2009 5:08 PM

    more info on the program
    In zbw_XXX_exit program
    FORM f_bw_bccmtd USING    i_t_var_range TYPE zbw_rrs0_t_var_range
                     CHANGING e_t_range     TYPE rsdd_t_range.
    *--- current date
      DATA: l_current_date TYPE sy-datum.
    *--- initialize the variables
      CLEAR:   v_wa_var_range, v_exch_rate,
               v_exch_temp, v_wa_return.
    *--- get the appropriate value from input variable table
      READ TABLE i_t_var_range INTO v_wa_var_range
           WITH KEY vnam    = c_var_name3
                    iobjnm  = c_obj_name2
                    BINARY SEARCH.
      IF sy-subrc = 0.
        l_current_date = v_wa_var_range-low.
        l_current_date = l_current_date - 1.
        CLEAR v_wa_return.
    *--- populate return value
        v_wa_return-sign = c_sign.
        v_wa_return-opt  = c_opt_bt.
        CONCATENATE l_current_date+0(6) c_one INTO v_wa_return-low.
        v_wa_return-high  = l_current_date.
        APPEND v_wa_return TO e_t_range.
      ENDIF.
    ENDFORM.

  • BPS Variables of Type Exit (How To Document)

    Hello,
    I'm trying to restrict entries for (say) variable #2, based on the selection of variable #1. 
    I've just realised characteristic relationships cannot be used and need to use a user exit.  I've gone through the "How To" on BPS Variables of Type Exit and have gotten the function modules to working properly. 
    However when the function module attempts to pass the data to BPS Variable #2, BPS gives an ERROR saying that in order to write new values into variable #2, the variable must have a replacement path "USER DEFINED VALUES".
    However this is not possible as the replacement path must be set to "USER EXIT" so the function module can be activated.
    The only way around this is to tell the function module which BPS Variable it should choose to write the data to, if so does anyone the ABAP to store values into a BPS Variable.
    Right now would appreciate any comment on this.
    Kind regards,
    Marinos

    Hi Marc,
    Yes, the How To paper answers my problem, and when I run the program via se37 the correct variable selections are being populated in table ETO_CHARSEL.  However when values are passed to the BPS Variable, the first information message read "The Conditions were Adapted"  but no values are passed to the variable.  Then a second error message "Entry not possible, var does not have replacement type user-spec vals."  This seems to be a conundrum as the variable needs to be set as user-exit.
    Any thoughts?
    Marinos
    My Z_SIMPLE_RELATION code is
    FUNCTION Z_SIMPLE_RELATION.
    ""Local Interface:
    *"  IMPORTING
    *"     VALUE(I_AREA) TYPE  UPC_Y_AREA
    *"     VALUE(I_VARIABLE) TYPE  UPC_Y_VARIABLE
    *"     VALUE(I_CHANM) TYPE  UPC_Y_CHANM
    *"     VALUE(ITO_CHANM) TYPE  UPC_YTO_CHA
    *"  EXPORTING
    *"     VALUE(ETO_CHARSEL) TYPE  UPC_YTO_CHARSEL
    Change constant according to your needs
    TABLES: /BIC/MTASSTCAT.
    CONSTANTS:
    l_source_var TYPE upc_y_variable VALUE 'TCAPASST',
    l_source_area TYPE upc_y_area VALUE 'TCAP001P',
    l_use_restricted_values TYPE boole-boole VALUE 'X',
    l_buffer_call TYPE boole-boole VALUE 'X'.
    DATA:
    l_subrc LIKE sy-subrc,
    ls_return LIKE bapiret2,
    l_type LIKE upc_var-vartype,
    lto_varsel_all TYPE upc_yto_charsel,
    lto_varsel TYPE upc_yto_charsel,
    lto_var TYPE upc_yto_charsel,
    lt_chavl TYPE /bic/PTASSTCAT occurs 0,
    ls_chavl like line of lt_chavl,
    lto_chanm type upc_yto_cha.
    read source value
    CALL FUNCTION 'Z_VARIABLE_GET_DETAIL'
    EXPORTING
    i_area = l_source_area
    i_variable = l_source_var
    i_buffer = l_buffer_call
    IMPORTING
    e_subrc = l_subrc
    es_return = ls_return
    e_type = l_type
    eto_varsel_all = lto_varsel_all
    eto_varsel = lto_varsel
    eto_chanm = lto_chanm.
    IF l_subrc <> 0.
    MESSAGE i136(upc_fw) WITH l_source_var.
    Values of variable &1 cannot be determined
    EXIT.
    ENDIF.
    now, you are free to determine the logic on how to
    derive the values based on the source values.
    Example 1: determine the next year
    Assumptions:
    - we have only a single year in the selection
    - the variable is of type characteristic
    DATA: ls_varsel TYPE upc_ys_charsel,
    l_next_year(4) TYPE n,
    l_entries TYPE i.
    We have a single value for the year and only one characteristic
    => our value is stored in the first line
    IF l_use_restricted_values IS INITIAL.
    lto_var = lto_varsel_all.
    ELSE.
    lto_var = lto_varsel.
    ENDIF.
    READ TABLE lto_var INTO ls_varsel INDEX 1.
    check prerequisites:
    - record found?
    IF sy-subrc <> 0.
    MESSAGE i147(upc_fw) WITH l_source_var.
    Variable &1 does not contain any values
    EXIT.
    ENDIF.
    - exactly one record and characteristic?
    DESCRIBE TABLE lto_var LINES l_entries.
    IF l_entries <> 1.
    MESSAGE i534(upc) WITH l_source_var.
    Variable &1 must be restricted to a value
    EXIT.
    ENDIF.
    SELECT * FROM /BIC/PTASSTCAT INTO TABLE lt_chavl
      WHERE asset_clas = ls_varsel-low.
      if sy-subrc <> 0.
        MESSAGE e026(upc) WITH ls_varsel-low '0ASSET_CLAS'.
    Attribute value not found
      exit.
    endif.
    ls_varsel-seqno = '0000'.
    ls_varsel-chanm = '/BIC/TASSTCAT'.
    LOOP AT lt_chavl INTO ls_chavl.
    ls_varsel-seqno = ls_varsel-seqno + 1.
    ls_varsel-low = ls_chavl-/BIC/TASSTCAT.
    APPEND ls_varsel TO eto_charsel.
    ENDLOOP.
    ENDFUNCTION.

  • Data Type field read only in Data source for transaction data (PC_FILE)

    Hi folks,
    I need to change Data Type for some of the fields in "Field" tab in data source for transactional data. It became read only after I activate the data source. Need help in making it editable. All fields now have Data type=CHAR.
    Thanks

    Nevermind folks. I got it.

  • Output Variable - Type: Date - Problem with WSDL in Designer

    Greetings,
    We are seeking some information about the following:
    We have a process in Process Designer that has and output variable of the type: Date. When the process is activated and we connect to a WSDL in LC ES Designer we get both a DATE and CALENDAR in the Data View.
    Hope that is at least somewhat clear. Please respond with any help or questions.
    Thanks,
    Rick Kuhlmann
    Tech-Pro

    This is to distinguish between java.util.Date and java.util.Calendar types. If the date is returned as java.util.Date, it will be in the DATE.date field. If the date is returned as java.util.Calendar, it will be in the DATE.calendar field.
    There are a bunch of xPath dates function in the xPath builder you can use.
    Jasmin

  • Derivation from variable type authorization in exit

    Hi Experts,
    I have got a query with two variables "AUTH" type authorization and "DERI" which should be derivate from "AUTH".
    "DERI" is type Exit.
    my problem, in the exit "AUTH" is not in i_t_var_range. Where do I get the value of "AUTH" from, to use it in the exit logic?
    Thanks for your help
    Pierre

    I Peter
    I needed to make the same thing.
    Did you found a solution?
    Best regards
    Joã

  • Need a report_Batchwise Mvt type last transaction date qty

    Dear Gurus
    Please suggest me any standard report or Table for display below report.
    Batchwise>Mvt type>last transaction date>qty
    thanks in advance
    Mayur

    Hi,
    MB51 --- Material documents list.
    Regards,

  • What message type used by ALE in transactional data

    Hello friends,,,
          I wish to know what msg types are used in transactional data like PO, PR, etc in Materail tables???
    thanking you

    hello babi,
        Message Type         Technical Name
        Product                    PRODUCT
        Location Group/Assortment  LOCGRP
        Assortment Product         ASRTPRD
        Assortment Version         ASRTPRDVRSM
    Assortment Version for Space Management ASRTPRDVRSO
       Allocation and PO           ALLOCPO
       Markdown Proposals          MDPROP
        Open-to-Buy                 OTB
    complete details of ALE:
    http://help.sap.com/saphelp_nw04/helpdata/en/0b/2a6cdd507d11d18ee90000e8366fc2/plain.htm
    REgards
    Varun

  • Types of variables and exits with screen shots

    Hi folks,
    I want to know types of variables and Exits and  how they are useful in reporitng.
    Please can body send me the docs or procedures how to use this.
    Useful docs/screen shotts will be hightly appreciated n wiil be assigned points.
    thanks in advance.
    Urs,
    raki

    Hi,
    Variable types:
    http://help.sap.com/saphelp_nw04/helpdata/en/c1/759b3c4d4d8d15e10000000a114084/frameset.htm
    Customer Exits :
    http://help.sap.com/saphelp_nw04/helpdata/en/f1/0a56f5e09411d2acb90000e829fbfe/frameset.htm
    regards
    Happy Tony

  • Enable "dynamic date calculation" variable type

    When saving reporting date/period in a report variant, we may use "dynamic date calculation" to specific date as selection parameter.  But the "Dynamic date calculation" is not visible in some ABAP reports - only "Table Variable from TVARVC"  type is available for selection. 
    For those reports that are missing that variable type, how can we enable the "Dynamic date calculation" variable type to be visible?

    Hi Paco:
    Yes, they are z-reports, both have the same almost everything, created by the same ABAPer, for the same application SD, just grouping the data differently.
    It seems a screen (#100?) is missing,  In the old version, it's screen 100 where to activate the "D" and "B" variable types.  Now it goes to screen 281.
    Stacy

  • How To ... BPS Variables of type exit

    Dear All,
    I am reading the How To ... BPS Variables of type exit sap document.
    On chapter 3.3.1 step 10 to 12 it's explain how to populated variable, and check user exit action to display one value in fonction of an other one.
    Unfortunately on step 11, when I click on F4 I got nothing. I can't enter value.
    Would you please let me know if the system should be configured in a particular way ?
    Thanks

    Hi Luminy,
    If you have followed Step 2 with 2002 then you would have got that at f4
    regards
    Happy Tony
    <b>Points == Thanks</b>

Maybe you are looking for