Posts

Showing posts from June, 2018

ABAP 7.5 Syntax - FOR Statement - Examples 3 and 4

What does the below Report do? There is an internal table with two fields. We need to capture the contents of more than one field of the internal table into another internal table with a condition. What will be done usually? We will use LOOP statement with WHERE clause and append data for every row in the main internal table. Now we don't have to do that because of the introduction of the powerful FOR statement. Report Example 3: *&---------------------------------------------------------------------* *& Report ZAG_TEST_FOR_TWO *&---------------------------------------------------------------------* *& *&---------------------------------------------------------------------* REPORT  zag_test_for_two . *-> Local Data Declarations TYPES :  BEGIN  OF  lty_parent ,          no1  TYPE  i ,          no2  TYPE...

ABAP 7.5 Syntax - FOR Statement - Example 2

What does the below Report do? There is an internal table with two fields. We need to capture the contents of more than one field of the internal table into another internal table. What will be done usually? We will use LOOP statement and append data for every row in the main internal table. Now we don't have to do that because of the introduction of the powerful FOR statement. Report Example 2: *&---------------------------------------------------------------------* *& Report ZAG_TEST_FOR_TWO *&---------------------------------------------------------------------* *& *&---------------------------------------------------------------------* REPORT  zag_test_for_two . *-> Local Data Declarations TYPES :  BEGIN  OF  lty_parent ,          no1  TYPE  i ,          no2  TYPE  i ,    ...

ABAP 7.5 Syntax - FOR Statement - Example 1

What does the below Report do? There is an internal table with two fields. We need to capture the contents of one of the fields of the internal table into another internal table. What will be done usually? We will use LOOP statement and append data for every row in the main internal table. Now we don't have to do that because of the introduction of the powerful FOR statement. Report Example 1: *&---------------------------------------------------------------------* *& Report ZAG_TEST_FOR_ONE *&---------------------------------------------------------------------* *& *&---------------------------------------------------------------------* REPORT  zag_test_for_one . *-> Local Data Declarations TYPES :  BEGIN  OF  lty_parent ,          no1  TYPE  i ,          no2  TYPE  i ,     ...