Sie sind auf Seite 1von 9

SAP BW: Pass Selection Screen Values using Customer Exit Variables in RRI

Applies to:
SAP BW 3.5 / BI 7.0 consultants accustomed with SAP ABAP skills. For more information, visit EDW Homepage .

Summary
Explains the method of passing the Selection Screen values using Customer Exit Variables in Report-Report Interface in BW reporting. Author: Suraj Tigga

Company: Capgemini Consulting India Pvt. Ltd. Created on: 30 March 2011

Author Bio
Suraj Tigga is a Senior SAP BI / ABAP consultant at Capgemini Consulting, India. Suraj joined Capgemini Consulting in 2008 and has worked on multiple SAP BI implementation and support projects.

SAP COMMUNITY NETWORK 2010 SAP AG

SDN - sdn.sap.com | BPX - bpx.sap.com | BOC - boc.sap.com | UAC - uac.sap.com 1

SAP BW: Pass Selection Screen Values using Customer Exit Variables in RRI

Table of Contents
Scenario .............................................................................................................................................................. 3 Step-by-Step Solution ..................................................................................................................................... 3
BEx Query Details........................................................................................................................................................ 3 Transaction RSBBS (RRI Settings).............................................................................................................................. 4 User Exit Code (Function Module: EXIT_SAPLRRS0_001) ........................................................................................ 4 Execution ..................................................................................................................................................................... 6

Related Content .................................................................................................................................................. 8 Disclaimer and Liability Notice ............................................................................................................................ 9

SAP COMMUNITY NETWORK 2010 SAP AG

SDN - sdn.sap.com | BPX - bpx.sap.com | BOC - boc.sap.com | UAC - uac.sap.com 2

SAP BW: Pass Selection Screen Values using Customer Exit Variables in RRI

Scenario
Report-to-Report Interface (RRI) provides the flexibility to jump to target (receiver) online from a BW query (sender) within or outside of the Business Information Warehouse. RRI provides the flexibility to pass the selection screen values from source query to the target query but the alteration of the selection screen values are not possible directly in the Assignment Details (RRI Settings).Document explains the details to do the adjustment of the selection screen values using customer exit variables(Using enhancement RSR00001). Step-by-Step Solution Below are the steps involved to pass the selection screen values from source query to target query after doing changes to the creation date values(Source query gets a Creation Date as input , in the customer exit code the created date calculates the date range for previous month which passes to target query): BEx Query Details: Details about the Source and Target Queries User Exit Code (Function Module EXIT_SAPLRRS0_001): Code to fed Creation Date range (Previous Month) to Target Query based on Creation Date from Source Query.

Source Query
(Creation Date: 06/26/2009)

Report Report Interface Customer Exit (EXIT_SAPLRRS0_001)

Target Query
(Creation Date: 05/01/2009 05/26/2009)

BEx Query Details Step1: Source Query (YZSLBDD01_QUERY1)

Variable ZPM_BEGIN_DATE (Manual Entry)

SAP COMMUNITY NETWORK 2010 SAP AG

SDN - sdn.sap.com | BPX - bpx.sap.com | BOC - boc.sap.com | UAC - uac.sap.com 3

SAP BW: Pass Selection Screen Values using Customer Exit Variables in RRI

Step2: Target Query (YZSLBDD01_QUERY2)

Variable YS_CREATE (Customer Exit, Ready for Input) Transaction RSBBS (RRI Settings) Step1: Go to transaction RSBBS and do the setting for RRI connected to target query:

User Exit Code (Function Module: EXIT_SAPLRRS0_001) Step1: Go to enhancement (RSR00001), write the code corresponding to variable ZPM_BEGIN_DATE to create a index in the database table INDX:

SAP COMMUNITY NETWORK 2010 SAP AG

SDN - sdn.sap.com | BPX - bpx.sap.com | BOC - boc.sap.com | UAC - uac.sap.com 4

SAP BW: Pass Selection Screen Values using Customer Exit Variables in RRI

(Code would be written under I_STEP = 3) Database table INDX would be populated when the query YZSLBDD01_QUERY1 would be executed particular to the different user.

Step2: For the target query (YZSLBDD01_QUERY2) is executed, then the values would be calculated based on the values present in INDX: Variable YS_CREATE would be populated from the values stored in INDX table corresponding to variable ZPM_BEGIN_DATE.

SAP COMMUNITY NETWORK 2010 SAP AG

SDN - sdn.sap.com | BPX - bpx.sap.com | BOC - boc.sap.com | UAC - uac.sap.com 5

SAP BW: Pass Selection Screen Values using Customer Exit Variables in RRI

Debug Mode:

Index G_ID value is fetched from table INDX. Execution Step1: Go to the Portal and execute the source query for the below mentioned selection: Query: (YZSLBDD01_QUERY1)

Creation Date: 06/26/2009

SAP COMMUNITY NETWORK 2010 SAP AG

SDN - sdn.sap.com | BPX - bpx.sap.com | BOC - boc.sap.com | UAC - uac.sap.com 6

SAP BW: Pass Selection Screen Values using Customer Exit Variables in RRI

Query Output

Step2: Query output for target query: Query Output:

For the target query the creation date would range from (05/01/2009 05/26/2009).

SAP COMMUNITY NETWORK 2010 SAP AG

SDN - sdn.sap.com | BPX - bpx.sap.com | BOC - boc.sap.com | UAC - uac.sap.com 7

SAP BW: Pass Selection Screen Values using Customer Exit Variables in RRI

Related Content
For more information, visit EDW HomePage .

SAP COMMUNITY NETWORK 2010 SAP AG

SDN - sdn.sap.com | BPX - bpx.sap.com | BOC - boc.sap.com | UAC - uac.sap.com 8

SAP BW: Pass Selection Screen Values using Customer Exit Variables in RRI

Disclaimer and Liability Notice


This document may discuss sample coding or other information that does not include SAP official interfaces and therefore is not supported by SAP. Changes made based on this information are not supported and can be overwritten during an upgrade. SAP will not be held liable for any damages caused by using or misusing the information, code or methods suggested in this document, and anyone using these methods does so at his/her own risk. SAP offers no guarantees and assumes no responsibility or liability of any type with respect to the content of this technical article or code sample, including any liability resulting from incompatibility between the content within this document and the materials and services offered by SAP. You agree that you will not hold, or seek to hold, SAP responsible or liable with respect to the content of this document.

SAP COMMUNITY NETWORK 2010 SAP AG

SDN - sdn.sap.com | BPX - bpx.sap.com | BOC - boc.sap.com | UAC - uac.sap.com 9