Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

differnce between Modify table and append table

Former Member
0 Likes
916

Hi Abappers,

What is the major differnce between the following 2?

a)G_T_PROD-G_OP_INV_KG = G_OP_INV1.

MODIFY G_T_PROD INDEX G_READ_INDEX.

b)G_T_PROD-G_OP_INV_KG = G_OP_INV1.

APPEND G_T_PROD.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
874

FIRST STATEMETN MODIFIES EXISTING DATA OF ITAB.

SECOND STATEMENT ADDS A NEW RECORD INTO ITAB.

7 REPLIES 7
Read only

Former Member
0 Likes
875

FIRST STATEMETN MODIFIES EXISTING DATA OF ITAB.

SECOND STATEMENT ADDS A NEW RECORD INTO ITAB.

Read only

Former Member
0 Likes
874

Hi mansi,

1. Append

Inserts one more record at the end.

2. Modify

Modified/Edits the data of a particular record,

specified by the index number/record number.

regards,

amit m.

Read only

Former Member
0 Likes
874

I dont think modify you have specified will work

Modify itab from wa index i_index will change the indexed record with value of work area

& append will directly add a new record

Thanks

Sandeep

Reward if helpful

Read only

Former Member
0 Likes
874

hi

<b>modify</b> is used to make changes to the existing data and modifyfing the table after inserting records .

but <b>append</b> statement is used to insert new record at the end of the table

hope ur doubts will get clear.

regards

ravish

<b>plz reward points if helpful</b>

Read only

Former Member
0 Likes
874

Hi,

Generally Append Statement Allows u to add a new record at the end of ur internal table.

While ur modify Statement is used to edit or change any of the existing record in ur internal table based on any condition u specify.

jus check that modify statement's syntax.

ie,

MODIFY <itab> WHERE <condition>.

Hope this helps u.

****reward if useful.

Read only

Former Member
0 Likes
874

Hi Mansi Maskeri,

<b>Append Statement :</b>

This statement helps in adding the record at the bottom of the internal table.

<b>Example : append wa_tab to it_tab.

This adds the record at the end of the internal table it_tab.</b>

<b>Modify statement :</b>

This statement helps in changing the existing record at the specified index.

For example:

modify it_tab index 3.

This modifies the internal it_tab record which is present at the 3 position.

Regards.

Read only

Former Member
0 Likes
874

Hi,

1). "Modify" modifies the the current internal table.

For eg. Modify itab from wa_itab.

Or Modify itab from wa_itab transporting...............

No additional records are added at the end.

2). "Append" appends(Adds) a record to the end of the table.

For eg. We use append in displaying data using ALV, wheer we append the contents to the fieldcatalog.So, the contents are added one after the other, and the result is finally dispalyed on screen.

Thanks and regards,

Prerna