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 Table issue

Former Member
0 Likes
594

Hi All,

I have two internal tables.

itab1 is having Production Number (aufnr) and other details.

itab2 is having Operation Numbers (afvc-vornr) associated with itab1-aufnr. But itab2 is not having Prod Order number (aufnr) field.

Now i need to pass itab2-vornr data to itab1. I can move this field to itab1 by looping both internal tables.

If itab2 is having more than 1 operation number (say 3) for single production order of itab1, how to pass the data to itab1...??????

Please help me with syntax.....

Regards

Pavan

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
572

hi pavan,

the structure of itab1 one and itab2 should be same. suppose if u wannna move itab2-vofnr to itab1, vofnr must be the field of itab1.

you can move only the value associated to that field.

Regards,

alosn.

6 REPLIES 6
Read only

Former Member
0 Likes
573

hi pavan,

the structure of itab1 one and itab2 should be same. suppose if u wannna move itab2-vofnr to itab1, vofnr must be the field of itab1.

you can move only the value associated to that field.

Regards,

alosn.

Read only

Former Member
0 Likes
572

Hi Pavan ,

If that is the case then you will have to create multiple entries for the same Production number in the internal table itab1.

Regards

Arun

Read only

0 Likes
572

Thanks for your responses..

How to create multiple entries in itab1 for the same Ptoduction Order..????

Read only

0 Likes
572

Hi Pavan ,

Do you have the feild <b>vornr</b> in your internal table itab1.

Regards

Arun

Read only

Former Member
0 Likes
572

i think you have to take a common field in both the itab. i can suggest you take aufpl fields from afko and afvc table in itab1 and itab2.

now

loop at itab1.

read table itab2 with key aufpl = itab1-aufpl.

if sy-subrc = 0.

itab1-vornr = itab2-vornr.

modify itab1 index sy-tabix.

endif.

endloop.

regards

shiba dutta

Read only

Former Member
0 Likes
572

Thanks for your Help...

It has been solved...

Have a great day ahead...

Regards

Pavan