Skip to Content
avatar image
Former Member

Reduce number of disk reads for a select statement..

Hi Experts,

I had a Select statement like this ,

SELECT approval_agent

FROM zmep_sc_app_hist

INTO CORRESPONDING FIELDS OF TABLE t_tab_approval_agent

WHERE item_guid EQ us_sc_i_guid

AND appr_description NE c_con_valid.

which is causing high number disk reads in the Production system,

so i got a suggesion that,if we remove the Negative checks like " NE" in select statemant

and removing the "CORRESPONDING FILEDS ".... will improve performance..

Does this reduce the number of disk reads..?

please suggest if I change the above select like this does it improve performance..or decrease the disk reads ..

SELECT approval_agent

FROM zmep_sc_app_hist

INTO CORRESPONDING FIELDS OF TABLE t_tab_approval_agent

WHERE item_guid EQ us_sc_i_guid

Delete zmep_sc_app_hist where appr_description NE c_con_valid.

Regards

sivaram

Add comment
10|10000 characters needed characters exceeded

  • Follow
  • Get RSS Feed

1 Answer

  • Apr 21, 2009 at 02:10 PM

    Hello,

    Just my thoughts...

    1) If only approval_agent is in t_tab_approval_agent, then use INTO TABLE t_tab_approval_agent

    2) If SELECT in nested within a loop, then use FOR ALL ENTRIES.

    If you look into the ABAP Forums, there are many threads regarding performance. Please take some time and review those threads.

    Regards, Dean.

    Add comment
    10|10000 characters needed characters exceeded