2009 Mar 05 12:34 PM
Hi;
My requirement is to first of all retrieve the data from different segments in run time.
I mean, i have to execute t/code WE19 and the idoc will be given after that an user exit would called where i have to retrieve the data from different segments and then it would store in an internal table for further calculation.
Can you all please guide me how to retrieve the data via ABAP code in runtime so that it can store in an internal table.
Regards
Shashi
Hi;
My requirement is to first of all retrieve the data from different segments in run time.
I mean, i have to execute t/code WE19 and the idoc will be given after that an user exit would called where i have to retrieve the data from different segments and then it would store in an internal table for further calculation.
Can you all please guide me how to retrieve the data via ABAP code in runtime so that it can store in an internal table.
Regards
Shashi
2009 Mar 06 4:51 AM
In user exit you will be getting Import parameters, tables. From that read the segment and populate the required data. For custom fields it will be 255 characters length and you have to read the offset of them.
2009 Mar 06 5:00 AM
write code lke this ..
form post_idoc tables idoc_data structure edidd
idoc_status structure bdidocstat .
loop at idoc_data .
case idoc_data-segnam .
when 'zsegment1'.
move idoc_data-sdata to wa_zsegment1 .
when 'zsegment2'.
move idoc_data-sdata to wa_zsegment2 .
when 'zsegmentn'.
move idoc_data-sdata to wa_zsegmentn.
endcase .
endloop.
After this write code to move data to int table from work area .
endform .
Hope this helps u....
2009 Mar 06 5:08 AM