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

Corresponding Statement

Former Member
0 Likes
561

Dear Experts,

I hv two internal table i_Bseg and i_faglflexa. And both contains some common fields.

Now I want to append i_faglflexa table with i_bseg fields which is common in both.

How can i do this ?

shall my loop look something like this?

loop at i_bseg.

append corresponding i_bseg to i_faglflexa.

endloop.

Need ur suggestion.

Regards

Maverick

you could have solved it on your own with a little more effort

Edited by: Suresh Datti on Sep 2, 2009 11:55 AM

4 REPLIES 4
Read only

Former Member
0 Likes
519

Hi,

Try like this,



loop at i_bseg.
move-corresponding i_bseg to i_faglflexa.
append i_faglflexa.
clear i_faglflexa.
endloop.

Regards,

Vikranth

Read only

former_member194669
Active Contributor
0 Likes
519

Keep both table fields in same order then


append lines of i_bseg into i_faglflexa.

Then no need of loop

Read only

Former Member
0 Likes
519

Dear ,

Use this.

loop at i_bseg into wa_bseg.

move-corresponding wa_bseg to wa_faglflexa.

append wa_faglflexa to i_falflexa.

clear: wa_faglflexa, wa_bseg.

endloop.

Regards,

Vijay

Read only

Former Member
0 Likes
519

HI, I would suggest to use the existing program logic to move the similar fields from one internal table to other, rather than writing seperate logic for the same.

Try to understand the existing logic , you will be able to reduce unnecessary statements for move.

Hope it helps you.