on 2020 Mar 06 11:24 AM
Hello Experts,
I am trying to achieve MOVE-CORRESPONDING with following scenario.
Internal Table #1: lt_plant
werks fabkl country
1000 01
Internal Table #2: lt_name
ident ltext
01 <Country Name>
I am trying to move the country name to from internal table #2 to internal table #1 using FOR with following code, however it's resulting in appending new rows from internal table #2.
lt_plant = value #( base lt_plant
for <fs_name> in lt_name
for <fs_plant> in lt_plant
where ( fabkl = <fs_name>-ident )
(
ltext = <fs_name>-ltext
) ).
Please help me to solve this using BASE/CORRESPONDING, FOR and WHERE.
Thanks in advance.
Request clarification before answering.
Hi sandra.rossi,
Greetings for the day !!
Thank you so very much for your support. Your code is working properly in terms of returning exact number of records as I have 114 records in the source table lt_plant. However, the werks field is getting initialized. Perhaps I will have to add werks too in the value assignment.I am attaching the screenshots, please suggest.


Thanks in advance.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Please use the COMMENT button for comments, questions, adding details, etc., ANSWER is only to propose a solution, dixit SAP text at the right of the answer area.
When it takes 10 seconds to test it yourself, I think you should try first, then ask if there's something you can't achieve or don't understand. So let's "spoon feeding": yes, the line is constructed from scratch so you must initialize all the components you want (I edited my answer too).
| User | Count |
|---|---|
| 28 | |
| 15 | |
| 14 | |
| 6 | |
| 5 | |
| 4 | |
| 4 | |
| 3 | |
| 3 | |
| 2 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.