Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

FM Performance Tuning

Former Member
0 Likes
627

Hi Experts,

Can anyone tell me how to do performance tuning wrt Function module. The steps will be very helpful.

Thanks in advance.

Regards

MGR

3 REPLIES 3
Read only

Former Member
0 Likes
544

Hi,

Usually the required logic can be written inside the function module. send the criteria as export parameters for which you want to get the data. write your select statements inside the function module. get the data in internal tables. later on you can process the internal table data according to your requirement.

thanks,

sksingh

Read only

Former Member
0 Likes
544

Hi,

Performance tuning for Function module should be same as reports

chk this

http://www.sap-img.com/abap/performance-tuning-for-data-selection-statement.htm

Read only

Former Member
0 Likes
544

Hi,

follow below steps

Hi,

<b> reduce database time</b>

1) Remove corresponding from select satement

2) Remove * from select

3) Select field in sequence as defined in database

4) Avoid unnecessary selects

i.e check for internal table not initial

5) Use all entries and sort table by key fields

7) Try to use secondary index when you don't have

full key.

FORM SUB_SELECTION_AUFKTAB.

if not it_plant[] is initial.

it_plant1[] = it_plant[].

sort it_plant1 by werks.

delete adjacent duplicates from it_plant1 comparing werks

SELECT AUFNR KTEXT USER4 OBJNR INTO CORRESPONDING FIELDS OF TABLE I_AUFKTAB

FROM AUFK

FOR ALL ENTRIES IN it_plant1

WHERE AUFNR IN S_AUFNR AND

KTEXT IN S_KTEXT AND

  • WERKS IN S_WERKS AND

AUART IN S_AUART AND

USER4 IN S_USER4 AND

werks eq it_plant1-werks.

free it_plant1.

Endif.

ENDFORM. "SUB_SELECTION_AUFKTAB

2) <b>reduce abap time</b>

1) Remove selects from loop and use binary search

2) Modify internal table use transporting option

3) Avoid nested loop . Use read table and loop at itab

from sy-tabix statement.

4) free intrenal table memory wnen table is not

required for further processing.

3)<b>Reduce sytsem time</b>Regards

1) perform give types of formal parameters

perform add using a b.

form add a type i b type i.

Regards,

amole

Regards

amole