Skip to Content
Former Member
Nov 27, 2009 at 07:21 AM

Suggest me less expensive SELECT for aggregate function.



I hv a SELECT statement with AGGREGATE function, but, as aggregates are expensive, so, want to replace it with less expensive SELECT statement, so, pls. let me know it, Wht can i use instaed, code is as below,

 CLEAR my_amount.
  SELECT SUM( wrbtr ) into my_amount from BSID
                          WHERE bukrs = p_bukrs
                          and   kunnr = p_konto
                          and   budat <= sy-datum. 

so, pls. let me know alternative(replace) SELECT which is less expensive performence wise

thank you