Raising an expection in variable exit: exit_saplrrs0_001

Hi,
The SAP documetation states:
I_STEP = 3
In this call up, you can check the values of the variables. Triggering an exception (RAISE) causes the variable screen to appear once more. Afterwards, I_STEP=2 is also called up again.
My question, how do I raise an exepction in this function module, there doesn't seem to be any exepctions defined in the interface?
Regards,
Ola

Hi,
Eg: I have a requirement to restrict the user entry for a variable in report for any date range of 12 months window. In case, user entry is more than 12 months of date range then it should raise a message on report screen.
CALL FUNCTION 'RRMS_MESSAGE_HANDLING'
          EXPORTING
            I_CLASS  = 'CD'
            I_TYPE   = 'E'
            I_NUMBER = '121'
            I_MSGV1  = 'Enter value for Created On'
         i_msgv2  = '<Message part 2>'
          EXCEPTIONS
            DUMMY    = 0
            OTHERS   = 0.
      RAISE NO_PROCESSING.
http://help.sap.com/saphelp_nw70/helpdata/EN/1d/ca10d858c2e949ba4a152c44f8128a/content.htm
How do you use i_step=3 in global variable user exit (EXIT_SAPLRRS0_001)
RRMS_MESSAGE_HANDLING in I_STEP3 of User Exit
Regards,
Suman

Similar Messages

  • Debugging the variable Exit  -  EXIT_SAPLRRS0_001

    Hi Guys
    Not sure how to debug the variable exit with setting break point.
    I need to check if my variable it correctly populated after written code in ZXRSRU01 .
    Any help will be awarded.
    Thanks in advance
    Kirk

    Hi Kirk,
    after When'Data Source'.
    Write : <b>BREAK-POINT</b>
    Save and activate the code and execute the report. Provide required input and execute. It will go into debugging more.
    Dont forget to remove the "break-point" before transporting to Quality/Production.
    Hope it helps.

  • Error Message in user-exit  EXIT_SAPLRRS0_001 in Query

    Hi,
    ABAP BW Guru's
    I got an ABAP  type problem with RANGE numeric variables  in EXIT_SAPLRRS0_001.
    With character or dates iuser-exits worke fine.
    My characteristic is CONNID Type  NUMC 4
    My user-exit variable is named CONNID_EXIT_STEP_2.
    My ABAP processing in the exit for the user-exit varibale is quite simple (testcase):
      DATA: l_e_t_range TYPE rsr_s_rangesid.
      l_e_t_range-low  =  '17'.
      l_e_t_range-opt  =  'EQ'.
      l_e_t_range-sign =  'I'.
      APPEND  l_e_t_range      TO   e_t_range.
    My Error message in the BEX Analyser is:
    Value "17" for user-exit variable CONNID_EXIT_STEP_2 is inavlid.
    What's wrong with the ABAP processing in the exit  (testcase) ?
    The debugger clearly shows l_e_t_range-low with value 17.
    l_e_t_range-low  seems is a character.
    Anyone can give a tip ?
    Thank You !
    Martin
    ThanXs

    Dear Karthik,
    You are right. First time my user exit execute, after that report automatically call message located Function Module LCOPDU13 504th row
         IF NOT SY-MSGID IS INITIAL.
           MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
              WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    Message number is 806 message id is RU.
    Can you help me for fix this situation? I just want to add a data control in ZXCOFU05 user exit. For user fill data (werks based)
    Thanks your helpful answer

  • Urgent: Issue with variable exit

    Hi All,
    We are having a requirement where in we need to populate the value of calday as the first day of the month that the user selects in the variable. For that, this is what i did:
    1. Created a variable for 0CALDAY as ZDAT1 and made it as "Processing Type --> SAP exit"
    2. Then i went to transaction SMOD and went to the enhancement RSR00001
    3. And then went to the exit EXIT_SAPLRRS0_001 and wrote the logic for the requirement,in the INCLUDE ZXRSRU01.
    4. Activated the include and exit
    However, after that when i executed the query i got an error saying that the Exit RSVAREXIT_ZDAT1 for variable ZDAT1 either does not exists or is inactive. For this reason I went to se37 and found that RSVAREXIT_ZDAT1 exit was inactive (I didnot manually create RSVAREXIT_ZDAT1, guess it was system created), so i put my piece of coding in it with the mandatory import and export parameters.However,  after that, the code was not getting called after the user enters the input, even if i put I_STEP =2. Can you please point out as to where i went wrong.
    Best Regards,
    Debashree.

    Hi Debashree,
    you should create the variable for processing type as 'customer exit' not SAP exit.
    hope this helps.

  • BW Customer Exit EXIT_SAPLRRS0_001

    I am trying to limit the values in the selection screen for a BW report using the BW customer exit EXIT_SAPLRRS0_001.  I have created a custom table to store values to limit the selection.  Unfortunately when coding for i_step = 2 I can only populate the field in the selection screen but the user is still able to click the multiple values button and see all values and not just the ones the limited to their user ID.  How can I limit this selection so the user cannot select any value but only the ones corresponding to their ID in the custom table ?  Also how can I de-activate the second text box in the selection so no range can be input ?  This is for setting up security for reporting.  Any help would be very much appreciated.

    to control the kind of input selection options displayed in the selection screen you have to configure and choose between different variables you create in the Bex.
    look for options in the Bex variable creation for single value selection only.
    in the customer exit.. stop at I_STEP = 3 and check if user input is correct .. else error out.
    If you can predict the correct user entries the user should make.. then you rather make this variable "not available for selection" and fill it in user exit yourself so the security is not breached. This way user cannot tamper with the values you fill in background. But he can filter further later in the query navigation.
    Thanks
    Sharan

  • VARIABLE EXITS

    Hi floks;
    I need some information on why and how to create variable exits in BEx? can you please give me and business scenarios why to create variable exits and virtual KF exits? any documents would be highle appreciated also. [email protected]
    Regards:
    Gandaki

    Hi,
    Customer or Variable exit is done in CMOD transaction. There are 2 kinds of Exit project available for BEX one at the Data target level EXIT_SAPMRSRU_001 and one at the query level EXIT_SAPLRRS0_001.
    Please see document below,
    http://help.sap.com/saphelp_nw04/helpdata/en/f1/0a56f5e09411d2acb90000e829fbfe/content.htm
    Hope this helps
    Arun

  • Customer Exit  EXIT_SAPLRRS0_001

    Hi Experts,
    can some make pointer regarding the authorisation in the exit EXIT_SAPLRRS0_001
    1)Value Authorization
    2)Hierarchy Authorization.
    which one will be better, and in detail about both the Authorization.
    Thankyou.

    I am not so sure what you mean about authorization...
    If  you mean the variable is to used to define OLAP authorizations, you need to code customer exit for this variable with i_step=0 (see note 492504)
    If you want to control authorization to access query data, you need to setup OLAP authorization in transaction RSECADMIN for BW 7.0.  Here, of course you can define authorization based on value or hierarchy node.

  • Variable exit in sap bi 7.0  is not working in web report

    Hi Experts,
        I had wrote a variable exit to get latest run date at variable screen for a variable.On the base query i have created query view.This query view is working fine when i am viewing from analyzer  but on  the web Im not getting latest run date but it taking some other date.
    Can  any body suggest any thing why system is behaving so strange.
    Thanks
    Vinod

    Hi, Succhi
    Note 1621031 - Incorrect status I1054 "To be distributed"
    Note 1620893 - Screen output without connection to user - SMQ1
    also check program CRM_DATAEXCHANGE_TOOLBOX
    Denis

  • How to debug variable exit in Bi 7.0

    Hi Experts,
          I  have code in variable exit in Bi 7.0, I am trying to debug in RSRT but im not able see my source code, Can you any body suggest me any thing or can suggest me steps to debug variable exit in bi 7.0.
    Thanks
    Vinod Kumar

    Hi Vinod,
    1) add following code into your exit-routine, at ??? fill your user-name:
    Routine will STOP here,
    than in new session call transaction SM50
    find your query-request and mark the line
    now go to menue line to -program/session and -debugging
      DATA: help.
      WHILE help IS INITIAL
        AND sy-uname = '???'.
      ENDWHILE.
    2) after activation of exit-rountine start your query
    3) open new session and call transaction SM50
    4) check the list and look for your query-request and mark the line
    5) now go to menue line to -program/session and -debugging
    6) the run will stop at your while-statement
    7) now you must change the contents of the variable help to '1' to leave the while-loop
    8) with F5-Key you can proceed your coding
    Regards
    Edi
    Edited by: Eduard Meder on Feb 19, 2009 12:40 PM

  • Help in Variable exit in Bi 7.0

    Hi Experts,
        For my requirement  I need write a variable exit in BI 7   based on start date and end date.1)If  user enquiry date is  lies between current month +last 2 month then get data of 3 months ie current month( complete data   before current week) + last 2month.  2)If user enquiry date lies beyond (current month + last 2 months ) then he get only data on which date lies.Can any suggest me how write variable exit  for requirement and what would be abap code i need  in variable exit.
    Thanks
    Vinod
    Edited by: vinod  kumar on Jan 27, 2009 5:35 AM

    Hi Vinod,
      Check here.........
    Customer Exit variable
    Customer Exit for Query Variable
    Customer Exit for Query Variable
    Re: variable customer exit
    Thanks,
    Vijay.

  • Variable Exit for Displaying last transaction or opening bal

    Dear Experts,
    material            year                period              amt         qty            
    abc                   2008                  01                4545         878
    abc                   2008                  03                5255         900
    def                   2008                  02                4333         1212
    def                   2008                  05                4551         1555  
    like wise data is stored in infocube , i am going to create a query based on the infocube . In query i define a variable for period and year respectively .if i give the input of period as 02 and year 2008 for the opening stock should get displayed as
    abc                   2008                  01                4545         878
    def                   2008                  02                4333         1212 
    if i give input of period as 10 and year as 2008 i should get the values as
    abc                   2008                  03                5255         900
    def                   2008                  05                4551         1555  
    and also pls let me know how and where  to write the variable exit
    PS: This is Go Live Critical
    Thanks and regards,
    raj

    Hi Frank.
    Im sure its possible to find the date last year, but it will involve some programming and thinking about time/dates etc, unless you can do a lookup in the factorycalendar or "normal" calendar, stored in the system AND having the number of day info.
    But you want to do this on the fly, in the report? I think performance might take a hit...
    regards
    jacob
    Edited by: Jacob Jansen on Oct 8, 2009 8:53 PM
    Edited by: Jacob Jansen on Oct 8, 2009 8:54 PM

  • Calculating difference between two dates in Variable Exits

    Hi,
          I need to calculate the difference between the two dates in months in Variable exits. I want the result in months so that I need to find out the Average Usage.
            How can I find the difference between them in months.
    Thanks
    Dave.

    Hi Christophe, Senthil
                                       Sorry for late response, I checked this  MONTHS_BETWEEN_TWO_DATES_NEW  in SE37/SE38 and about the date they are going to enter at query run time it should be like 03/03/2006 to 08/03/2006 and I should get in 5 months and or if the date range 03/15/2006 to 08/03/2006 and I should get like 4.5 months. Please could you tell me how to get the values in months or please give me a functional module so that I can use.
    Thanks
    Dave.

  • How do I...Mimic Replacement Path with Query using Customer Variable Exits?

    Hello SDN:
    We are on BW 3.5 SP16.
    We are currently using a replacement path Query(RP) with variables
    to populate a variable in another Query(T).
    The problem we are having is with performance.
    The entry of variables in replacement path Query(RP) is optional (This is necessary there cannot be required values)
    When results from Replacement Path Query are small performance is fine. (e.g. 10 seconds)
    When results from Replacement path query are large performance suffers. (e.g. 1+ minutes)
    Users are free to leave the replacement path variables empty resulting in a large set of data to be replaced. This is the worst performance case.
    We would like to discover a way to conditionally execute the replacement path query. That is if users do not enter values for the replacement Query(RP) variables do not execute the replacement path query(RP).
    Does anyone know if this is possible within reason and in customer exit space?
    We have reviewed the situation from all angles and the requirement for the replacement path FUNCTIONALITY and the freedom for the user to leave variable values blank remains.
    I've been searching and reading SDN and SAP notes for about a week and do not find threads which address this situation.
    We are also exploring Customer variable exits to mimic replacement path functionality
    (different topic subject="How do I...Mimic Replacement Path with Query using Customer Variable Exits?")
    Any help will be appreciated
    Many thanks
    David Schuh

    My appologies-I posted this message with the wrong subject. I will repost it with appropriate subject.
    dave schuh

  • Custome variable exit for fiscal year/period

    Hello BW Gurus,
    Q1[1,2,3] Q2[4,5,6] Q3[7,8,9] Q4[10,11,12] quarterly periods
    I have a custom variable exit as shown for fiscal year period
           IF LOC_VAR_RANGE-LOW+4(3) =< '003'.
              L_S_RANGE-LOW+4(3) = '001'.
           ELSEIF LOC_VAR_RANGE-LOW+4(3) > '003' AND
                                              LOC_VAR_RANGE-LOW+4(3) =<'006'.
              L_S_RANGE-LOW+4(3) = '004'.
           ELSEIF LOC_VAR_RANGE-LOW+4(3) > '006' AND
                                                LOC_VAR_RANGE-LOW+4(3) =< '009'.
              L_S_RANGE-LOW+4(3) = '007'.
           ELSE.
              L_S_RANGE-LOW+4(3) = '010'.
           ENDIF.
    Now this works fine to give me the Current Quarter ....say if user puts 005/2007 i get the data Current quarter as [4+ 5] i.e. April and MAy data. Now for <b>Previous Period</b> I gave an offset as -3 to -1 inorder to get data for Q1[123] but the requirement is changed and I want the same time period i.e. [1+2] and not the entire quarter since the Current Quarter calculates only for 4 and 5.
    I hope u are getting my point....please give your suggestions will reciprocate with lots of points

    Hi gaurav,
    Basically If I am selecting period 005 I am getting the data for 4 and 5 as Current Quarter i.e. April is the starting period of that Q2.
    Similarly the previous Quarter should also give me data for period 1 and period 2.
    Right now the offset I gave is -3 to -1 on my custom variable so i am getting data for the entire previous quarter which is Q1[1,2,3] but in reality i just want data for period 1and period 2.
    Can you please help me in this
    Appreciate your concern
    Thanks

  • The window to select dimensions simply does not appear and I can't move forward, due to variables exit in the report

    Dear experts,
    I am having an issue when I try to create a WEBI document using Bex query through OLAP connection (Bics).
    Due to variables exit, it is not possible to open query pannel in webi to choose wich dimensions to add to the webi document.
    The window to select dimensions simply does not appear and I can't move forward!
    In RSRT ou Bex Analyzer, the query is running fine without errors.
    CMOD code is like this (I believe there is not any error as it is working flawless on other reports for other variable names):
    WHEN 'ZREDT1'.
         IF i_step = 2.
           CLEAR wa2.
           READ TABLE i_t_var_range INTO wa2 WITH KEY vnam = 'ZRE_DT_IN'.
    *      wa2-low = |{ v_year_h }12|.
           IF sy-subrc EQ 0.
             v_year_h = wa2-low(4) - 1.
             CONCATENATE v_year_h '12' INTO wa1-low.
    *        wa1-low = wa2-low.
             wa1-opt  = 'EQ'.
             wa1-sign = 'I'.
             APPEND wa1 TO e_t_range.
           ENDIF.
         ENDIF.
        WHEN 'ZREDT2'.
         IF i_step = 2.
           CLEAR wa2.
           READ TABLE i_t_var_range INTO wa2 WITH KEY vnam = 'ZRE_DT_IN'.
           IF sy-subrc EQ 0.
    *        wa2-low = |{ v_year_h }12|.
             v_year_h = wa2-low(4) - 1.
             CONCATENATE v_year_h '12' INTO wa1-low.
             wa1-opt  = 'EQ'.
             wa1-sign = 'I'.
             APPEND wa1 TO e_t_range.
           ENDIF.
         ENDIF.
    Please provide assistance,
    Thanks in advance,
    Kind regards,
    André Oliveira

    I solved it.
    The problem was due to date coming to exit - as you know some time intervals start at 01-01-1000, and as I was calculating 1000-1 = 999
    I was getting and interval from 99901 to 201405. Do not know if it was not working because CHAR NUMC6 was failing trying to recognize interval 99901 - 201405, but probably, this was the issue.
    Thanks for your inputs,
    Best regards,
    André Oliveira

Maybe you are looking for