Saturday, 28 June 2014

Performance Measure : Linear Search Vs Binary Search

Step1. Searching/Reading internal table mostly required in development. Though we have the key field to read, Binary search always performs better than the Linear search.


























Step2. O/P of Five consecutive runs:























-------------------------------------------------------xxxxx---------------------------------------------------------------

Performance Measure: Single Line Vs Column Update

Step1. Program with comparison between Single line update in the   database & column update in the database.





















Step2. O/P of five consecutive runs:















--------------------------------------------------xxxxx---------------------------------------------------------------------

Friday, 27 June 2014

Uses of SUPER keyword in OOABAP


Step1. Create a program and define the constructor in both the super and sub class. Constructor is always executed form the super class to the Sub class in OO concept. So if the object of the Sub class is created, then constructor of the sub class is called first and within this sub class constructor method using the SUPER keyword the super class constructor should be called other wise  we ll receive a compile time error. So mostly SUPER keyword is used in Inheritance concept where we have same method in both the SUPER & SUB class. Execute the program.




















Step2. The O/P is as follows:













Step3. Let's define a method in the super class and redefine it in the subclass as well. Call the Subclass method. Here calling the super class redefined method is optional but in case of constructor it is mandatory to call the super class constructor in the subclass constructor.


























Step4. The O/P is as follows:














--------------------------------------------------xxxxx-------------------------------------------------------------------

Comments system

Disqus Shortname