How to move the even records of one internal table to other
Answer Posted / n m s m krishna
DATA : BEGIN OF ITAB OCCURS 0,
KUNNR TYPE KUNNR,
END OF ITAB.
DATA : ITAB_EVEN LIKE ITAB OCCURS 0 WITH HEADER LINE.
DATA : ITAB_ODD LIKE ITAB OCCURS 0 WITH HEADER LINE.
SELECT KUNNR FROM KNA1 INTO TABLE ITAB UP TO 20 ROWS.
LOOP AT ITAB.
IF SY-TABIX MOD 2 = 0.
ITAB_EVEN-KUNNR = ITAB-KUNNR.
APPEND ITAB_EVEN.
ELSE.
ITAB_ODD-KUNNR = ITAB-KUNNR.
APPEND ITAB_ODD.
ENDIF.
ENDLOOP.
| Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
What are the dynamic actions and how to configure it? : sap abap hr
What are the data types of the abap/4 layer? : abap data dictionary
What are the basic components of dialog program?
Explain the advantages of different types of bdc's?
What is the difference between a structure and a table?
What are the personnel administration related Infotypes
Update types in Call transaction method. What is the difference?
Can we use transfer dataset to transfer data in internal table ?
10) How to get Item Header in Sales Order?
What is the use of the raising exception? : abap modularization
Explain what is step-loop?
What are the fields in a bdc_tab table? : abap bdc
What is tcode se16?
write a program for creation of customer quotation using BAPI 'BAPI_QUOTATION_CREATEFROMDATA'.
What are the advantages and disadvantages of different types of bdc's?