Monday, 3 February 2014

SAP BW/BI Useful Programs

RSIMPCURR - To Transfer Exchange Rates

RSIMPCUST - To Transfer Global Settings from source system

RS_TRANSTRU_ACTIVATE_ALL - To Activate Transfer Rules (Useful whenever we need to activate transfer rules in Quality or Production system after transports)

RSAU_UPDR_REACTIVATE_ALL - To Activate Update Rules

SAP_CONVERT_TO_TRANSACTIONAL - To change Basic Cube to Transactional Cube

RSAR_PSA_CLEANUP_DIRECTORY - To Clean PSA and Change log

SAP_INFOCUBE_DESIGN - To know statistics (Size) of Cubes (Useful to know the size of Fact Tables and Dimension Tables)

RSSM_SET_REPAIR_FULL_FLAG - To change request status from Full load to repair full (Useful to start delta loads, If full loads are already present in data target from same data source)

RSDDS_AGGREGATES_MAINTAIN - For Hierarchy/Attribute Change run

RSDDS_CHANGERUN_MONITOR - To Check Change run Status

RSDG_ODSO_ACTIVATE - To Activate ODS in background (Very much useful when BEx reporting switched on)

RSDG_IOBJ_ACTIVATE - To Activate Info objects (Mass Activation)

RSDG_MPRO_ACTIVATE - To Activate MultiProviders

RSDG_CUBE_ACTIVATE - Activation of InfoCubes

RS_COMSTRU_ACTIVATE_ALL - Activate all inactive communication structures

RSCONN07 - SAP Connect Administration (System Status)

RSAOS_METADATA_UPLOAD_BATCH - To replicate single data source from Source(R/3)

RSDRD_DELETE_FACTS - To delete data selectively from info provider (ODS or CUBE)

RSAR_LOGICAL_SYSTEMS_ACTIVATE - Activate All SAP Source Systems (After BW Upgrade)

RSDS_DATASOURCE_ACTIVATE_ALL - Activate All Data Sources of a Log System

RSTCC_ACTIVATE_ADMIN_COCKPIT - Perform all steps to activate the content for the BI Admin Cockpit

RSTCC_ACTIVATEADMINCOCKPIT_NEW - Activate Content for the BI Admin Cockpit



Important SAP tables

Easy way to remember all the main SAP tables used for any development:

Remember Bank tables start with B, say "BKNF , BKPF".
Remember Customer tables start with K , say "KNA1,KONV".
Remember Material tables start with M, say "MARA , MAKT , MARC".
Remember Master data tables start with T, say "T001, T001W".
Remember Purchasing tables start with E, say "EKKO, EKPO"
Remember Sales table start with V, say "VBAK,VBAP".
Remember Vendor tables start with L, say "LFA1".

Six important FI tables.

They contain an I if it is an open item.
They contain an A if it is a closed item.
They contain an S if a GL account say "BSIS , BSAS".

Important table names of Billing, Delivery, Sales and Purchasing.

Each table had a K if it is a header data, say "VBAK, VBAP, LIKP, VBRK, EKKO".
Each table had a P if it is an item data, say "VBAP, LIPS , VBRP , EKPO".
With a D at the end , the table is a Customer
With a K at the end, the table is a Vendor.



BI Useful tables :

Customer Info objects Tables

/BIC/M - View of Master data Tables
/BIC/P - Master data Table, Time Independent attributes
/BIC/Q - Master data Table, Time Dependent attributes
/BIC/X - SID Table, Time Independent
/BIC/Y - SID Tabel, Time Dependent
/BIC/T - Text Table
/BIC/H - Hierarchy Table
/BIC/K - Hierarchy SID Table



Standard Info objects Tables (Business Content):

Replace "C" with "0" in above tables.
Ex: /BI0/M - View of Master data Tables



Standard Infocube Tables :

/BI0/F - Fact Table(Before Compression)
/BI0/E - Fact Table(After Compression)
/BI0/P - Dimension Table - Data Package
/BI0/T - Dimension Table - Time
/BI0/U - Dimension Table - Unit
/BI0/1, 2, 3, .......A,B,C,D : - Dimension Tables



BW Tables:

BTCEVTJOB - To check List of jobs waiting for events
ROOSOURCE - Control parameters for Data source
ROOSFIELD - Control parameters for Data source
ROOSPRMSC - Control parameters for Data source
ROOSPRMSF - Control parameters for Data source
RSOLTPSOURCE - Replicate Table for OLTP source in BW
RSDMDELTA - Data mart Delta Management
RSSDLINITSEL, RSSDLINITDEL - Last valid Initialization to an OLTP Source
RSUPDINFO - Infocube to Info source correlation
RSUPDDAT - Update rules key figures
RSUPDENQ - Removal of locks in the update rules
RSUPDFORM - BW: Update Rules - Formulas - Checking Table
RSUPDINFO - Update info (status and program)
RSUPDKEY - Update rule: Key per key figure
RSUPDROUT - Update rules - ABAP routine - check table
RSUPDSIMULD - Table for saving simulation data update
RSUPDSIMULH - Table for saving simulation data header information
RSDCUBEIOBJ - Info objects per Infocube
RSIS – Info source Info
RSUPDINFO - Update Rules Info
RSTS - Transfer Rules Info
RSKSFIELD - Communication Structure fields
RSALLOWEDCHAR - Special Characters Table(T Code : RSKC, To maintain)
RSDLPSEL - Selection Table for fields scheduler(Info package's)
RSDLPIO - Log data packet number
RSMONICTAB - Monitor, Data Targets(Infocube/ODS) Table, request related info
RSTSODS - Operational data store for Transfer structure
RSZELTDIR - Query Elements
RSZGLOBV - BEx Variables
RXSELTXREF, RSCOMPDIR - Reports/query relevant tables
RSCUSTV - Query settings
RSDIOBJ – Info objects
RSLDPSEL - Selection table for fields scheduler(Info package list)
RSMONIPTAB – Info Package for the monitor
RSRWORKBOOK - Workbooks & related query genuine id's
RSRREPDIR - Contains Genuine id, Report Name, Author, etc...
RSRINDEXT - Workbook ID & Name
RSREQDONE - Monitor: Saving of the QM entries
RSSELDONE - Monitor : Selection for expected requests
RSLDTDONE - Texts on the requested info packages & groups
RSUICDONE - BIW: Selection table for user-selection update Infocubes
RSSDBATCH - Table for Batch run scheduler
RSLDPDEL - Selection table for deleting with full update scheduler
RSADMINSV - RS Administration
RSSDLINIT - Last Valid Initializations to an OLTP Source
BTCEVTJOB -To check event status(scheduled or not)
VARI - ABAP Variant related Table
VARIDESC - Selection Variants: Description
SMQ1 - QRFC Monitor(Out Bound)
SM13 - Update Records status

ASAP Methodologies : ASAP stands for Accelerated SAP

ASAP Methodologies
ASAP stands for Accelerated SAP. Its purpose is to help design SAP implementation in the most efficient manner possible. Its goal is to effectively optimize time, people, quality and other resources, using a proven methodology to implementation. ASAP focuses on tools and training, wrapped up in a five-phase process oriented road map for guiding implementation.The road map is composed of five well-known consecutive phases:
• Phase 1 Project Preparation
• Phase 2 Business Blueprint
• Phase 3 Realization
• Phase 4 Final Preparation
• Phase 5 Go-Live and support 

Phase 1 : Project Preparation Phase

One initiates with a retrieval of information and resources. It is an important time to assemble the necessary components for the implementation. Some important milestones that need to be accomplished for phase 1 include
• Obtaining senior-level management/stakeholder support
• identifying clear project objectives
• architect an efficient decision-making process
• creating an environment suitable for change and re-engineering
• building a qualified and capable project team.

Senior level management support:
One of the most important milestones with phase 1 of ASAP is the full agreement and cooperation of the important company decision-makers - key stake holders and others. Their backing and support is crucial for a successful implementation.

Clear project objectives:
be concise in defining what your objectives and expectations are for this venture. Vague or unclear notions of what you hope to obtain with SAP will handicap the implementation process. Also make sure that your expectations are reasonable considering your company's resources. It is essential to have clearly defined ideas, goals and project plans devised before moving forward.

An efficient decision making process:
One obstacle that often stalls implementation is a poorly constructed decision-making process. Before embarking on this venture, individuals need to be clearly identified. Decide now who is responsible for different decisions along the way. From day one, the implementation decision makers and project leaders from each area must be aware of the onus placed on them to return good decisions quickly.

Environment suitable for change and re engineering: Your team must be willing to accept that, along with new SAP software, things are going to change, the business will change, and information technology enabling the business will change as well. By implementing SAP, you will essentially redesign your current practices to model more efficient or predefined best business practices as espoused by SAP. Resistance to this change will impede the progress of your implementation.

ASAP- Second Phase- Business Blueprint

SAP has defined a business blueprint phase to help extract pertinent information about your company that is necessary for implementation. These blueprints are in the form of questionnaires that are designed to probe for information that uncovers how your company does business. As such, they also serve to document the implementation. Each business blueprint document essentially outlines your future business processes and business requirements. The kinds of questions asked are germane to the particular business function, as seen in the following sample questions:

1) What information do you capture on a purchase order?

2) What information is required to complete a purchase order?

Accelerated SAP question and answer database: The question and answer database (QADB) is a simple although aging tool designed to facilitate the creation and maintenance of your business blueprint. This database stores the questions and the answers and serves as the heart of your blue print. Customers are provided with a customer input template for each application that collects the data. The question and answer format is standard across applications to facilitate easier use by the project team.
Issues database:
Another tool used in the blueprinting phase is the issues database. This database stores any open concerns and pending issues that relate to the implementation. Centrally storing this information assists in gathering and then managing issues to resolution, so that important matters do not fall through the cracks. You can then track the issues in database, assign them to team members, and update the database accordingly.

ASAP Phase- 3 - Realization:

With the completion of the business in phase 2, "functional" experts are now ready to begin configuring SAP. The Realization phase is broken in to two parts.
1) Your SAP consulting team helps you configure your baseline system, called the baseline configuration.
2) Your implementation project team fine-tunes that system to meet all your business and process requirements as part of the fine tuning configuration.

The initial configuration completed during the base line configuration is based on the information that you provided in your blueprint document. The remaining approximately 20% of your configuration that was not tackled during the baseline configuration is completed during the fine tuning configuration. Fine tuning usually deals with the exceptions that are not covered in baseline configuration. This final bit of tweaking represents the work necessary to fit your special needs.

Configuration Testing:
With the help of your SAP consulting team, you segregate your business processes into cycles of related business flows. The cycles serve as independent units that enable you to test specific parts of the business process. You can also work through configuring the SAP implementation guide (IMG). A tool used to assist you in configuring your SAP system in a step by step manner.

Knowledge Transfer:
As the configuration phase comes to a close, it becomes necessary for the Project team to be self-sufficient in their knowledge of the configuration of your SAP system. Knowledge transfer to the configuration team tasked with system maintenance (that is, maintenance of the business processes after Go-live) needs to be completed at this time.In addition, the end users tasked with actually using the system for day-to-day business purposes must be trained.

ASAP Methodology - Phase 4 - Final Preparation:

As phase 3 merges into phase 4, you should find yourselves not only in the midst of SAP training, but also in the midst of rigorous functional and stress testing. Phase 4 also concentrates on the fine tuning of your configuration before Go-live and more importantly, the migration of data from your old system or systems to SAP.
Workload testing (including peak volume, daily load, and other forms of stress testing), and integration or functional testing are conducted to ensure the accuracy of your data and the stability of your SAP system. Because you should have begun testing back in phase 2, you do not have too far to go until Go-live. Now is an important time to perform preventative maintenance checks to ensure optimal performance at your SAP system.At the conclusion of phase 4, take time to plan and document a Go-live strategy. Preparation for Go-live means preparing for your end-users questions as they start actively working on the new SAP system.

ASAP - Phase 5 - Go-live and Support:

The Go-live milestone is itself is easy to achieve; a smooth and uneventful Go-live is another matter altogether. Preparation is the key, including attention to what-if scenarios related not only to the individual business processes deployed but also to the functioning of technology underpinning these business processes and preparation for ongoing support, including maintenance contracts and documented processes and procedures are essential. 


Reconciliation

What is reconciliation?

Reconciliation is nothing but the comparison of the values between BW target data with the Source system data like R/3.

In general this process is taken at 3 places one is comparing
(1)The info provider data with R/3 data,
(2) Compare the Query display data with R/3 or DSO data
(3) Checking the data available in info provider kefigure with PSA key figure values.
The ultimate purpose is that, data in R/3 and data in BW/BI should tally (if we use formulas and routines etc in BI then data differ from R/3)


Few T-Codes for BI performance tuning

T-Code
Description
SM66
Global Work Process Overview
ST02
Tune Summary
ST06
System monitor
STAD
SAP workload
ST05
SQL Trace
SE30
ABAP Trace
ST12
Single transaction analysis(including ST05/ST30)
RSMO
BW Load monitor
DB02
DB Load overview
ST04
DB Performance snapshot
RSBATCH
BI Background management
RSODSO_SETTINGS
Maintenance of runtime parameter of DSO
RSRV
Analysis and repair BI Objects
ST03
Workload in system
RSRT
Query Monitor
RSRTRACE
Configure Trace Tool

Common Production Support Issues with Resolutions of SAP BI

1. DTP Failure
Select the step-> right click and select “Display Message”-> there we will get the message which gives the reason for ABEND.
A DTP can failure due to following reasons, in such case we can go for restarting the job.
  • System Exception Error
  • Request Locked
  • ABAP Run time error.
  • Duplicate records
  • Erroneous Records from PSA.
Duplicate records:
            In case of duplication in the records, we can find it in the error message along with the Info Provider’s name. Before restarting the job after deleting the bad DTP request, we have to handle the duplicate records. Go to the info provider -> DTP step -> Update tab -> check handle duplicate records -> activate -> Execute DTP. After successful competition of the job uncheck the Handle Duplicate records option and activate. 

DTP Log Run:
  • If a DTP is taking log time than the regular run time without having the back ground job, then we have to turn the status of the DTP into Red and then delete the DTP bad request (If any), repeat the step or restart the job.
  • Before restarting the Job/ repeating the DTP step, make sure about the reason for failure.
  • If the failure is due to “Space Issue” in the F fact table, engage the DBA team and also BASIS team and explain them the issue. Table size needs to be increased before performing any action in BW. It’ll be done by DBA Team. After increasing the space in the F fact table we can restart the job. 
Erroneous Records from PSA: 
When ever a DTP fails because of erroneous records, while fetching the data from PSA to Data Target, in such cases data needs to be changed in the ECC. If it is not possible, then after getting the approval from the business, we can edit the Erroneous records in PSA and then we have to run the DTP.
Go to PSA -> select request -> select error records -> edit the records and save.
Then run the DTP. 

2.      INFO PACKAGE FAILURE: 

The following are the reasons for Info Pack failure.
  • Source System Connection failure
  • tRFC/IDOC failure
  • Communication Issues
  • Processing the IDOC Manually in BI
  • Check the source system connection with the help of SAP BASIS, if it is not fine ask them to rebuild the connection. After that restart the job (Info Pack).
Go to RSA1 -> select source system -> System -> Connection check.
  • In case of any failed tRFC’s/IDOC’s, the error message will be like “Error in writing the partition number DP2” or “Caller 01, 02 errors”. In such case reprocess the tRFC/IDOC with the help of SAP BASIS, and then job will finish successfully.
  • If the data is loading from the source system to DSO directly, then delete the bad request in the PSA table, then restart the job
  • Info Pack Long Run: If an info pack is running long, then check whether the job is finished at source system or not. If it is finished, then check whether any tRFC/IDOC struck/Failed with the help of SAP BASIS. Even after reprocessing the tRFC, if the job is in yellow status then turn the status into “Red”. Now restart / repeat the step. After completion of the job force complete.
  • Before turning the status to Red/Green, make sure whether the load is of Full/Delta and also the time stamp is properly verified.
  • Time Stamp Verification:
Select Info Package-> Process Monitor -> Header -> Select Request -> Go to source System (Header->Source System) -> Sm37-> give the request and check the status of the request in the source system -> If it is in active, then we have to check whether there any struck/failed tRFC’s/IDOC’s 

If the request is in Cancelled status in Source system -> Check the Info Pack status in BW system -> If IP status is also in failed state/cancelled state -> Check the data load type (FULL or DELTA) -> if the status is full then we can turn the Info Package status red and then we can repeat/restart the Info package/job. -> If the load is of Delta type then we have to go RSA7 in source system-> (Compare the last updated time in Source System SM37 back ground job)) Check the time stamp -> If the time stamp in RSA7 is matching then turn the Info Package status to Red -> Restart the job. It’ll fetch the data in the next iteration

If the time stamp is not updated in RSA7 -> Turn the status into Green -> Restart the job. It’ll fetch the data in the next iteration.


Source System
BW System
Source System RSA7
Source System SM37
Action
I/P Status RED(Cancelled)
I/P Status (Active)
Time stamp matching with SM37 last updated time
Time stamp matching with RSA7 time stamp
Turn the I/P Status into Red and Restart the Job
I/P Status RED(Cancelled)
I/P Status (Cancelled)
Time stamp matching with SM37 last updated time
Time stamp matching with RSA7 time stamp
Turn the I/P Status into Red and Restart the Job
I/P Status RED(Cancelled)
I/P Status (Active)
Time stamp is not  matching with SM37 last updated time
Time stamp is not matching with RSA7 time stamp
Turn the I/P status into Green and Restart the job
I/P Status RED(Cancelled)
I/P Status (Cancelled)
Time stamp is not  matching with SM37 last updated time
Time stamp is not matching with RSA7 time stamp
Turn the I/P status into Green and Restart the job

  • Processing the IDOC Manually in BI:
When there is an IDOC which is stuck in the BW and successfully completed the background job in the source system, in such cases we can process the IDOC manually in the BW.
Go to Info Package -> Process Monitor -> Details -> select the IDOC which is in yellow status(stuck) -> Right click -> Process the IDOC manually -> it’ll take some time to get processed.

Note: Make sure that we can process the IDOC in BW only when the back ground job is completed in the source system and stuck in the BW only.

3.      DSO Activation Failure:

When there is a failure in DSO activation step, check whether the data is loading to DSO from PSA or from the source system directly. If the data is loading to DSO from PSA, then activate the DSO manually as follows
  • Right click DSO Activation Step -> Target Administration -> Select the latest request in DSO -> select Activate -> after request turned to green status, Restart the job.
  • If the data is loading directly from the source system to DSO, then delete the bad request in the PSA table, then restart the job
4.      Failure in Drop Index/ Compression step:

When there is a failure in Drop Index/ compression step, check the Error Message. If it is failed due to “Lock Issue”, it means job failed because of the parallel process or action which we have performed on that particular cube or object. Before restarting the job, make sure whether the object is unlocked or not
There is a chance of failure in Index step in case of TREX server issues. In such cases engage BASIS team and get the info reg TREX server and repeat/ Restart the job once the server is fixed.
Compression Job may fail when there is any other job which is trying to load the data or accessing from the Cube. In such case job fails with the error message as “Locked by ......” Before restarting the job, make sure whether the object is unlocked or not.

5. Roll Up failure:

“Roll Up” fails due to Contention Issue. When there is Master Data load is in progress, there is a chance of Roll up failure due to resource contention. In such case before restarting the job/ step, make sure whether the master data load is completed or not. Once the master data load finishes restart the job.  

6. Change Run – Job finishes with error RSM 756

When there is a failure in the attribute change run due to Contention, we have to wait for the other job (Attribute change run) completion. Only one ACR can run in BW at a time. Once the other ACR job is completed, then we can restart/repeat the job.
            We can also run the ACR manually in case of nay failures.
Go to RSA1-> Tool -> Apply Hierarchy/Change Run -> select the appropriate Request in the list for which we have to run ACR -> Execute.

7. Transformation In-active:

In case of any changes in the production/moved to the production without saving properly or any modification done in the transformation without changing, in such cases there is a possibility of Load failure with the error message as “ Failure due to Transformation In active”.

In such cases, we will have to activate the Transformation which is inactive. 
Go to RSA1 -> select the transformation -> Activate
In case of no authorization for activating the transformation in production system, we can do it by using the program - RSDG_TRFN_ACTIVATE
Try the following steps to use the program "RSDG_TRFN_ACTIVATE” here you will need to enter certain details:
Transformation ID: Transformation’s Tech Name (ID)
Object Status: ACT
Type of Source: “Source Name”
Source name: “Source Tech Name”
Type of Target: Target Name
Target name: “Target Tech Name”
  1. Execute. The Transformation status will be turned into Active.
Then we can restart the job. Job will be completed successfully. 

8. Process Chain Started from the yesterday’s failed step:

In few instances, process chain starts from the step which was failed in the previous iteration instead of starting from the “Start” step.
In such cases we will have to delete the previous day’s process chain log, to start the chain form the beginning (from Start variant).
Go To ST13-> Select the Process Chain -> Log -> Delete.
Or we can use Function Module for Process Chain Log Deletion: RSPROCESS_LOG_DELETE.
Give the log id of the process chain, which we can get from the ST13 screen.
Then we can restart the chain.

Turning the Process Chain Status using Function Module:

At times, when there is no progress in any of the process chains which is running for a long time without any progress, we will have to turn the status of the entire chain/Particular step by using the Function Module.

Function Module: RSPC_PROCESS_FINISH

The program "RSPC_PROCESS_FINISH" for making the status of a particular process as finished.
To turn any DTP load which was running long, so please try the following steps to use the program "RSPC_PROCESS_FINISH" here you need to enter the following details:
LOG ID: this id will be the id of the parent chain.
CHAIN: here you will need to enter the chain name which has failed process.
TYPE: Type of failed step can be found out by checking the table "RSPCPROCESSLOG" via "SE16" or "ZSE16" by entering the Variant & Instance of the failed step. The table "RSPCPROCESSLOG" can be used to find out various details regarding a particular process.
INSTANCE & VARIANT: Instance & Variant name can be found out by right clicking on the failed step and then by checking the "Displaying Messages Options" of the failed step & then checking the chain tab.
STATE: State is used to identify the overall state of the process. Below given are the various states for a step.
R Ended with errors
G Successfully completed
F Completed
A Active
X Canceled
P Planned
S Skipped at restart
Q Released
Y Ready
Undefined
J Framework Error upon Completion (e.g. follow-on job missing)


Sunday, 5 January 2014

Process Chain

Process Chains can define interdependent processes with tasks like data loading, InfoCube compression, index maintenance, Master Data & ODS activation in the best possible performance & data integrity. Process Chains exist in administrator work bench.
Each time we cannot manually go and execute infopackage , DTP, activate request in DSO etc...
jobs like this are scheduled using a process chain.


Process chains are used to automate the process of objects.
The T-code for  creating new process chain is RSPC

The T-code for monitor all process chains is RSPCM 

Local Chain: This is the simple process chain. 
Meta Chain: This is the main chain which contains one or more local chains

Note: Before you define process chains, you need to have the Objects ready i.e DSO, InfoCubes etc.

Example: Process chain flow for Infocube
  


Example: Process chain flow for DSO
Example: Process chain flow for Master data attribute