thespot4sap.com independent sap information
 

New - get SAP Access - pay monthly

SAP Tutorials    Online SAP Training    SAP CBT's    Forums    SAP Articles    SAP Jobs    Resumes
  SAP Access    SAP Blogs    SAP Books     Links     Vendor Directory     Submit Content    Search

New Page 1

Previous Page

Next Page

SAP ABAP Performance Tuning
Tips & Tricks
Using Aggregate Functions

Page 3 of 15

Use of aggregate functions

Use the already provided aggregate functions, instead of finding out the minimum/maximum values using ABAP code.

Not recommended

            Maxnu = 0.

            Select * from zflight where airln = ‘LF’ and cntry = ‘IN’.

             Check zflight-fligh > maxnu.

             Maxnu = zflight-fligh.

            Endselect.

 

Recommended

            Select max( fligh ) from zflight into maxnu where airln = ‘LF’ and cntry = ‘IN’.

The other aggregate functions that can be used are min (to find the minimum value), avg (to find the average of a Data interval), sum (to add up a data interval) and count (counting the lines in a data selection).

===================================================================================

This tutorial contains a number of pages, each one explaining a tip or trick. You can either browse them one by one (click on the NEXT button, or jump straight to a tip or trick which interests you:

Next Page

Previous Page

 

New Page 1

 

 


About Us   Contact Us   Privacy   Disclaimer   Feedback   Email Discussion   Newsletter  

Copyright © - Independent SAP Information
Partners: Learn XML, SAPdox, Worldwide Guesthouses and B&B's