ABAP Performance Tuning - Tips & Tricks
Content
Introduction
Using Selection Criteria
Using Aggregate Functions
Using Views instead of Base Tables
Using the Into Table clause
Modifying a group of lines
Use of Binary Search option
Appending Internal Tables
Using Table Buffering
Use of FOR ALL entries
Proper Structure of the WHERE clause
Proper use of the MOVE statement
Proper use of INNER JOIN statement
Use ABAP SORT instead of ORDER BY
Performance Analysis Tools
  ABAP Performance Tuning - Tips & Tricks
-Use of Binary Search option-
 
Page 7 Of 15

Use of binary search option

When a programmer uses the read command, the table is sequentially searched. This slows down the processing. Instead of this, use the binary search addition. The binary search algorithm helps faster search of a value in an internal table. It is advisable to sort the internal table before doing a binary search. Binary search repeatedly divides the search interval in half. If the value to be searched is less than the item in the middle of the interval, the search is narrowed to the lower half, otherwise the search is narrowed to the upper half. 

Not Recommended

            Read table int_fligh with key  airln = ‘LF’.

 

Recommended

            Read table int_fligh with key  airln = ‘LF’ binary search.

 
Stats Box
Vendor Listings (9)
Jobs (3)
Resumes (3)
Tutorials (18)
Articles (22)
Code Snippets (1)
CBTs (17)
Books (4)
Online Training (15)
Latest 5 Tutorial
SAPscript
SAP Mobile Engine
Integrating XML into SAP Business Connector
Lotus Notes Integration
SAP Data Archiving
 
Copyright © 2007 SapDox.com. All rights Reserved.