Posts

Showing posts with the label Programming

ABAP Insights: Demystifying Internal Table Operations - Sorting Tricks, Smart Data Summation, and Table Types Unveiled

Image
 Welcome back everyone, So basically we were discussing about internal table operations in our last blog. So let’s continue it. Internal Table Operations - SORT :- It is to sort the internal table. If we are not specifying anything, then by default it sorts in the ascending order. If we want to sort in descending order, then we need to specify the keyword descending. Practical implementation :- ************************************************* *Start of Program SORT lt_header BY order_number. "here we have not specified "anything, then by default it " will sort in ascending order. *Printing data LOOP AT lt_header INTO ls_header. WRITE :/ ls_header-order_number, ls_header-payment_mode. ENDLOOP. *End or Program ******************************************************** Output :- Sorting in Descending Order :- ************************************************* *Start of Program SORT lt_header BY order_number DESCENDING. *Printing data LOOP AT lt_header INTO

Unlocking ABAP Mastery: A Comprehensive Guide to Internal Table Operations - Loop, Delete, Modify, Read, Clear, Describe

Image
 Welcome back everyone, So basically we have started with internal table operations in our last blog. So let’s continue it. Internal Table Operations - Loop :- Loop allows you to execute a group of statements multiple times. Loop at <itab> where stands for internal table. Loop is used to read the records one by one from the internal table. Practical Implementations :- *********************************************************** *Start Of Program *Using loop LOOP AT lt_header INTO ls_header. WRITE :/ ls_header-order_number, ls_header-payment_mode. ENDLOOP. *End of Program. ************************************************************ Output :- Internal Table Operations - DELETE :- Delete is used to delete the records from the internal table. There are two ways to perform delete operations. Delete based on where condition. Delete based on index. Delete based on where condition :- ********************************* *Start of Program *Using delete to delete