Implementing Customer Exit Reporting Variables as Methods

Similar documents
SAP BI Global Report Variable user exit modularization

BI Reporting user Exit Implementation Through Dynamic Class with Interface

Using Customer Exit Variables in BW/BI Reports: Part - 14

Using Customer Exit Variables in BW/BI Reports Part - 1

Reporting Duplicate Entries

Using Customer Exit Variables in BW/BI Reports: Part - 4

Easy Lookup in Process Integration 7.1

Extracting Missing Fields of Data Source Which Are Present In Their Extract Structure

Triggering the Process Chains at Particular Date using Events

POWL: Infoset Generation with Web Dynpro ABAP

Routines in SAP BI 7.0 Transformations

Download SAP Query Output to Local/ Network Folders in Background

DB Connect with Delta Mechanism

Restricting F4 (Input Help) Values While Running a SAP BW Query

Creating Custom SU01 Transaction Code with Display and Password Reset Buttons

Creation of Sets in SAP-ABAP, How to Read them INI SAP-ABAP Reports

Reading Enhanced DataSource fields for the Remote Cube

Standalone BW System Refresh

Role and Scope of ABAP in SAP BI

Using Radio Buttons in Web Template

Integration of Web Dynpro for ABAP Application in Microsoft Share Point Portal

Data Extraction & DS Enhancement in SAP BI Step by Step

Graphical Mapping Technique in SAP NetWeaver Process Integration

SAP BI Analysis Authorization (Customer Exit Variables)

How to Work with F4 Input Help Effectively in BEX

This article explains the steps to create a Move-in letter using Print Workbench and SAPScripts.

How to use Boolean Operations in the Formula as Subsidiary for IF Condition

SMT (Service Mapping Tool)

Procedure to Trigger Events in Remote System Using an ABAP Program

About ITAB Duplicate_Key (SAP lrsaods) Runtime Error

SAP BW Copy Existing DTP for Data Targets

Customized Transaction to Trigger Process Chain from Failed Step

Material Master Archiving in Simple Method

Step by Step Guide on How to Use Cell Definition in BEx Query

Process Chain Log Deletion

SDN Community Contribution

Custom Process types Remote Trigger and End Time

Customizing Characteristic Relationships in BW-BPS with Function Modules

How to Default Variant Created for Report Developed In Report Painter/Writer

Displaying SAP Transaction as Internet Application in Portal

Recreating BIA Indexes to Address the Growth of Fact Index Table

Linking Documents with Web Templates

Limitation in BAPI Scheduling Agreement (SA) Create or Change

How to Create and Schedule Publications from Crystal Reports

Material Listing and Exclusion

Step by Step Procedure for DSO Creation

Maintaining Roles and Authorizations in BI7.0 - RSECADMIN

Creating, Configuring and Testing a Web Service Based on a Function Module

Database Statistics During ODS Activation

Financial Statement Version into PDF Reader

How to Configure User Status in mysap SRM

How to Create Top of List and End of List of the ALV Output in Web Dynpro for ABAP

Add /Remove Links on ESS Home Page in Business Package 1.5

How to Create View on Different Tables and Load Data through Generic Datasource based on that View

Generate Export Data Source

MDM Import Manager - Taxonomy Data (Attribute Text Values) Part 3

Transfer Material Attributes (Material Type) from R/3 to SAP GRC Global Trade Services (GTS)

Using Query Extract to Export Data from Business warehouse, With Pros and Cons Analyzed

MDM Syndicator: Custom Items Tab

How to Extend an Outbound IDoc

ecatt Part 6 System Data Container

Dynamically Enable / Disable Fields in Table Maintenance Generator

Creation of Key Figures with Higher Decimal Place Precision

How to Write Inverse Routine with Expert Routine

Table Row Popup in Web Dynpro Component

How to Display Result Row in One Line While Reporting On Multiproviderer

Web Dynpro: Coloring Table Conditionally

Adding Custom Fields to Contract Account Screen

SAP QM-IDI Interface. SDN Contribution. Applies to: Summary. Author Bio. SAP QM Interfaces

Information Broadcasting Part 3 Scheduling the First Report

Web Dynpro ABAP: Dynamic Table

Step by Step Guide for PI Server Start and Stop Procedure

Step by Step Method for File Archival in BW

Open Hub Destination - Make use of Navigational Attributes

Step By Step: the Process of Selective Deletion from a DSO

Step by Step Guide to Enhance a Data Source

A Step-by-Step Guide on IDoc-ALE between Two SAP Servers

List of Values in BusinessObjects Web Intelligence Prompts

Validity Table in SAP BW/BI

Steps to Activate ALE Delta for Custom Master Datasource Created on ZTable

SDN Community Contribution

Changing the Source System Assignments in SAP BW Objects without Affecting the Data Modeling

ABAP Code - Recipients (Specific Format) SAP BW Process Chain

Freely Programmed Help- Web Dynpro

Extraction of Hierarchy into Flat File from R/3 and Loading in BW System

Planning Functions and Characteristic Relationship in Integrated Planning

How to Broadcast BEx Workbooks using BW Pre-calculation Server and through Process Chains

How to Reference External JAR Files in Web Dynpro DC in SAP NW Portal 7.3

Open Text DocuLink Configuration - To Access Documents which are Archived using SAP

Data Flow During Different Update Mode in LO Cockpit

Using Nested Exception Aggregation in BEx Reports- Scenario

E-Sourcing System Copy [System refresh from Production to existing Development]

Xcelsius Tricks Part 5 Create a Loading Bar in SAP Crystal Dashboard and Presentation Design (Xcelsius 2008)

Web Dynpro ABAP: Changing ALV Contents and Saving in Database

Applies To:...1. Summary...1. Table of Contents...1. Procedure..2. Code... Error! Bookmark not defined.0

Step by Step Guide How to Use BI Queries in Visual Composer

SAP BI BO Unit/Currency Logic for Unknown Units Case Study

Internationalization in WebDynpro ABAP Applications

Setting up Connection between BW and R/3 for Data Load

Dialog Windows in WebDynpro ABAP Applications

Transcription:

Implementing Customer Exit Reporting Variables as Methods Applies to: SAP BI 7.0 For more information, visit the Business Intelligence homepage. Summary This article describes how we can implement customer exit reporting variables as methods of a global class. Instead of changing the customer exit for populating the values for reporting variable, every time a new customer exit variable is created, a new method of the same name as the variable is created. Author: Company: IBM Praveen M R Created on: 15 February 2009 Author Bio Praveen is a SAP Certified Consultant working for IBM India. His areas of expertise are and ABAP. BI 2009 SAP AG 1

Table of Contents Introduction...3 Solution...3 Include ZXRSRU01...3 Class ZC_BW_GLOBVAR...5 Validating Reporting Variables...7 Advantages...8 Related Content...8 Disclaimer and Liability Notice...9 2009 SAP AG 2

Introduction Global Reporting Variables of processing type Customer Exit allows you to use a function module exit to set default values for variables. This is the function module EXIT_SAPLRRS0_001. The enhancement RSR00001 (BI: Enhancements for Global Variables in Reporting; transaction SMOD; component or function module EXIT_SAPLRRS0_001) is called several times during the execution of the report. The I_STEP parameter specifies when the enhancement is called. When the number of Customer Exit processing type variables increases, the current standard solution of implementing the customer exit in the include, becomes unmanageable and difficult to control and coordinate between developers in a multi team environment. In scenarios of parallel development between different developers, there is a high chance of untested code getting transported across the landscape. This could lead to unavailability of BI reports in the system. Here, we look into a solution to avoid all those issues. Solution In the proposed solution, the code for populating the reporting variable will be implemented as a class method of a global class. This solution has two parts. The Global Class ZC_BW_GLOBVAR The Include ZXRSRU01 The class ZC_BW_GLOBVAR needs to be created in class builder SE24. Whenever a new customer exit variable is created, a new method of same name is added to the class ZC_BW_GLOBVAR and the code for populating the customer exit variable needs to be written inside the method. If a variable ZVBPFYPD is created in the variable maintenance screen, a new method ZVBPFYPD will be added to the class. Include ZXRSRU01 Create a project in the CMOD transaction, select SAP enhancement RSR00001 and assign it to the enhancement project. Activate the project. In the main include ZXRSRU01, the below code needs to be added. TRY. IF I_STEP <> 3. CALL METHOD ZC_BW_GLOBVAR=>(I_VNAM) EXPORTING I_VNAM = I_VNAM I_VARTYP = I_VARTYP I_IOBJNM = I_IOBJNM I_S_COB_PRO = I_S_COB_PRO I_S_RKB1D = I_S_RKB1D I_PERIV = I_PERIV I_T_VAR_RANGE = I_T_VAR_RANGE I_STEP = I_STEP IMPORTING E_T_RANGE = E_T_RANGE E_MEEHT = E_MEEHT E_MEFAC = E_MEFAC E_WAERS = E_WAERS E_WHFAC = E_WHFAC CHANGING C_S_CUSTOMER = C_S_CUSTOMER. ELSE. CALL METHOD ZC_BW_GLOBVAR=>STEP3 EXPORTING I_VNAM = I_VNAM 2009 SAP AG 3

I_VARTYP = I_VARTYP I_IOBJNM = I_IOBJNM I_S_COB_PRO = I_S_COB_PRO I_S_RKB1D = I_S_RKB1D I_PERIV = I_PERIV I_T_VAR_RANGE = I_T_VAR_RANGE I_STEP = I_STEP IMPORTING E_T_RANGE = E_T_RANGE E_MEEHT = E_MEEHT E_MEFAC = E_MEFAC E_WAERS = E_WAERS E_WHFAC = E_WHFAC CHANGING C_S_CUSTOMER = C_S_CUSTOMER. ENDIF. IF SY-SUBRC = 0. EXIT. ENDIF. CATCH CX_SY_DYN_CALL_ERROR. ENDTRY. 2009 SAP AG 4

Class ZC_BW_GLOBVAR In the class builder (SE24) create class ZCBW_GLOBVAR. For each reporting variable create a public static method of same name. 2009 SAP AG 5

The parameter interface for the methods should be. 2009 SAP AG 6

Now we can write the code for populating the report variable in the method that we created. Validating Reporting Variables The customer exit EXIT_SAPLRRS0_001 is also used to check the values of the reporting variables, this is done when I_STEP = 3 and when as exception is triggered the variable screen appears again. Creating a public static method STEP3 in class ZC_BW_GLOBVAR and writing the code inside the method, we can implement this validation. 2009 SAP AG 7

Advantages This approach prevents the situation where the main program SAPLXRSR having post transport syntax errors leading to unavailability of all the BI reports in the system. Hence eliminating the effort and time required to correct these post transport syntax errors and the down time for BI reports. One time change to the user exit include. Enables parallel development of reporting variables efficiently. Related Content SAP Library - BI Suite - Reporting Variables -Customer Exit SAP Library - Customer Exits SAP Library - Class Builder For more information, visit the Business Intelligence homepage. 2009 SAP AG 8

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. 2009 SAP AG 9