Skip to Content
0
Jan 10, 2011 at 01:40 PM

How to upload idoc data ?

161 Views

Hi,

I have downloaded idoc in text file

1. for this i have passed the document number in IDOC_READ_COMPLETELY.

2. from the above i got the control records and data records .

3. i have appended both in internal table.

4. then i have downloaded in flat file.

5. the user requirement is the downlaoded file can be modified and again i need to upload.

6 . my question is how to read the uploaded data in flat file.( all data comes in one column , how to separate control record and data record)

7. how to know what data has been updated in flat file.

Please help me to resolve the above prob..

My code :

data :

IT_data TYPE ZTABLE , "(line type char (1063)

wa_data LIKE LINE OF IT_DATA.

MOVE-CORRESPONDING WA_IDOC_CONTROL TO WA_EDI_DC40. " control record

WA_EDI_DC40-TABNAM = 'EDI_DC40'.

WA_EDI_DC40-IDOCTYP = WA_IDOC_CONTROL-IDOCTP.

WA_itab = WA_EDI_DC40.

APPEND WA_itab TO IT_itab.

LOOP AT IT_EDIDD INTO WA_EDIDD. " data record

MOVE-CORRESPONDING WA_EDIDD TO WA_EDI_DD40.

WA_itab= WA_EDI_DD40.

APPEND WA_itab TO IT_itab

ENDLOOP.

Regards,

Rachel