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

Internal Tables

Former Member
0 Likes
1,175

Hi experts,

What is the fastest way to move one i_tab1 to another i_tab2? Assuming two tables of similar structure. Pls explain.

a) append lines of table1 to table2.

b) loop at table1.

Move: table1-field1 to table2-field1,

table1-field2 to table2-field2.

Append table2.

Endloop.

c) table2[] = table1[].

d) loop at table1.

Move-corresponding table1 to table2.

Endloop.

e) move table1 to table2.

Regards,

Marc

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,148

Hi Marc,

Option C is the fastest one compared to option A....

It moves all the contents faster than the other.

regards,

Priyanka.

12 REPLIES 12
Read only

Former Member
0 Likes
1,148

Hi Marc

I would recommend method A and C if the structures are same.

Kind Regards

Eswar

Read only

RichHeilman
Developer Advocate
Developer Advocate
0 Likes
1,148

Assuming that you want to move all rows of the internal table.

A and C if the structure of the internal tables exactly the same.

D if the structures are different.

Regards,

Rich Heilman

Read only

gopi_narendra
Active Contributor
0 Likes
1,148

Option C is the best

secondly A

Regards

- Gopi

Read only

Former Member
0 Likes
1,148

method a and c is the best

regards

shiba dutta

Read only

Former Member
0 Likes
1,148

HI,

My priority is

1.C

2.A

Read only

Former Member
0 Likes
1,148

Option C would be the best option if both the internal table structures are same.

Regards,

Rajesh

Read only

Former Member
0 Likes
1,148

Hi,

If both have same structure then go fo option C

itab1[] = itab2[].

Read only

Former Member
0 Likes
1,149

Hi Marc,

Option C is the fastest one compared to option A....

It moves all the contents faster than the other.

regards,

Priyanka.

Read only

0 Likes
1,148

hi,

if both the structures of itabs are same then go for this.

table2[] = table1[].

rgds

Anver

Read only

0 Likes
1,148

If structure is the same,

Option C is the best. 2nd. Option will be A.

Regards,

Oscar

Read only

Former Member
0 Likes
1,148

hi Marc,

c) table2[] = table1[].

Reggars,

Santosh

Read only

baskaran00
Active Participant
0 Likes
1,148

Hi,

U can use option c. And one more, u can use

INSERT LINES OF ITAB INTO TABLE JTAB.

itab and jtab should be similar in structure.