Flipkart.com

Friday, October 1, 2010

How to improve the performance of PNP LDB?

There has always been a complaint on Logical Databases, that they are slow. Here is a list of startegies to use PNP LDB better.

1. Use macro RP_SET_DATA_INTERVAL in the INITIALIZATION event.
Read here on how to use the macro.

2. For Time infotypes (2000, 2001, 2002) use Mode N, so that they are not fetched during GET event. After the GET event use Macro RP_READ_ALL_TIME_ITY for fecthing the time infotypes within a selected data range. Usually there will be huge number of records in Time infotypes. Hence it is better to fetch the required records in the code using macro.

3. Use the INITIALIZATION event to fill the selection screen (Pernr / person selection period) so as to limit the number of employees fetched.
Example requirement: The report needs to run only for the employees who have an email id in infotype 105.
Solution: In the INITIALIZATION event fetch all employees who have a valid email ID in IT105. Populate these pernrs in to selection screen pernr field.

4. Skip the employees who have left the company
Majority of the times you may not need to fetch the employees who have left the company.
In INITIALIZATION, Use the macro RP-SEL-EIN-AUS-INIT.

5. No SELECT statements within the loop GET Perenr ---- END_OF_SELECTION.
Try to do all database fetch either before GET Pernr or after END-OF-SELECTION. Doing a SELECT inside GET means that the SELECT executes for every pernr.

2 comments:

  1. thank you so much,,it helped me :)

    ReplyDelete
  2. Hi, I wish to be a regular contributor of your blog. I have
    read your blog. Your information is really useful for us.
    Best Hadoop Institute Certification & Placement From India


    ReplyDelete