‎2008 Apr 15 2:52 PM
hi experts...
i just want to ask if is it possible that append command will not be successfully executed?
data:begin og it_detail occurs 100.
pernr like pa0001-pernr,
name like pa0001-ename,
data: end of it_Detail.
data it_pernr like pa0001-pernr occurs 100.
data it_name like pa0001-ename occurs 100.
table contents:
10000001 name1
10000002 name2
10000004 name3
loop at it_Detail
append it_detail-pernr to it_pernr.
append it_detail-name to it_name.
endoop.
i am expecting it_pernr table has same
number of records with it_name.
but to my surprise..it_pernr has 3 contents
and it_name has 2.
this was the result at the production system..
i was not able to simulate again but based on the workflow container(SWI2_FREQ)...
they have diffent number of contents..
maybe upon executing the command
append it_detail-name to it_name.
it was not stored successfully to the internal table..
any idea why 1 of the record was not stored at it_name talble..?
thanks,,,
‎2008 Apr 15 3:03 PM
Are you sure that name only has 2 entries, or does it have ONE empty line as well.
The only thing I can think of is that field name is empty, but is appended to internal table anyway with an empty line.
‎2008 Apr 15 3:08 PM
thanks micky for your reply...
it_name has only 2 records.
no empty line was appended to it_name since
all of the entries at table it_detail has a value.
i am expecting 3 records since it_Detail-ename has 3..
any idea why it was not appended?
Edited by: jr_sap_developer on Apr 15, 2008 4:12 PM
‎2008 Apr 15 3:13 PM
is that the real code?
Doesn't work for me
Is that the real entries?
‎2008 Apr 15 3:21 PM
nope...
i did not paste all the source code..
actually it_detail has 10+ fields...
i only declared 2 field for me two show the problem..
‎2008 Apr 15 3:16 PM
Hi,
check this one.
it is working.
data:begin of it_detail occurs 100,
pernr like pa0001-pernr,
name like pa0001-ename.
data: end of it_Detail.
data it_pernr like pa0001-pernr occurs 100.
data it_name like pa0001-ename occurs 100.
it_detail-pernr = 10000001.
it_detail-name = 'name1'.
append it_detail.
it_detail-pernr = 10000002 .
it_detail-name = 'name2'.
append it_detail.
it_detail-pernr = 10000004.
it_detail-name = 'name3'.
append it_detail.
loop at it_Detail.
append it_detail-pernr to it_pernr.
append it_detail-name to it_name.
endloop.
<REMOVED BY MODERATOR>
raam
Edited by: Alvaro Tejada Galindo on Apr 15, 2008 10:48 AM
‎2008 Apr 15 3:28 PM
thank you for your reply...
i was not able to re run the workflow at the production system but i was able to simulate it at qas server..
my codes are working fine at qas..
the result was the same number of records both it_pernr and it_name,,,
i have no idea why it_pernr and it_name has diff number od records at PROD system..this happen only once..
as of today, all are working fine..i just cant explain to our functional what happen why 2 tables have diiferent number of contents...
is it possible that system slowdows causes the append command not succesfull?
‎2008 Apr 15 3:47 PM