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

What is the Transaction/Program which gets triggered when file

Former Member
0 Likes
1,194

What is the Transaction or Program which gets triggered when file has been placed on application server to generate the Inbound IDoc from the same.

Please let me know the procedure to automate the process of generating Inbound IDoc when the file has been placed in application server path...

Thanks for your reply ....

regards,

G.Reddy

What is the Transaction or Program which gets triggered when file has been placed on application server to generate the Inbound IDoc from the same.

Please let me know the procedure to automate the process of generating Inbound IDoc when the file has been placed in application server path...

Thanks for your reply ....

regards,

G.Reddy

6 REPLIES 6
Read only

Former Member
0 Likes
975

Hi,

Check the below link specially the comment by shibuettickal .

[Link1|]

Thanks,

Asit Purbey.

Read only

Former Member
0 Likes
975

I dont think SAP has any program which will trigger when specific file is received. You have to create

program and run periodically to see if file exists if "Yes' then populate the

MASTER_IDOC_DISTRIBUTE to create the IDOC so if you see this will be custom application.

Regards

Shital

Read only

0 Likes
975

Hi Shital,

Thanks for the response. the FM MASTER_IDOC_DISTRIBUTE is used to generate the IDoc in the Outbound process, not in Inbound.

I know that FM EDI_DATA_INCOMING can be used to create the inbound Idoc from file. What I wanted to know specifically is, if there is any Program which can be used to do the same from external system.

Regards,

Govardhan Reddy

Read only

Former Member
0 Likes
975

Hi ,

this is the function module triggered when file has been placed on application server to generate the Inbound IDoc from the same and the file s picked from the port which the path is specified..

EDI_PATH_CREATE_CLIENT_DOCNUM..

there is no automatica process to create the idoc from application server..

Triggering the Inbound Process

After receiving an inbound EDI transmission and creating an IDoc file, the subsystem is often responsible for triggering the inbound process. SAP provides a program named startrfc to start any RFCu2212enabled function module from the operating system level. For the EDI process, the subsystem uses the start rfc program to trigger the function module EDI_DATA_INCOMING.

Regards,

Prabhudas

Read only

Former Member
0 Likes
975

Hi

Step 1 : you have to create a 'Zprogram' and schedule a background job which is very frequently executed in the background ( for ex : every 6 min's ) which senses that an inbound file has been received ( This file will be placed in a specified directory (inbound) in the application server ).

Step 2 : Further the data in file has to be processed. To achieve this another job has to be scheduled which will be linked to an event. The details of the job will be maintained in the TBTCO table and details of events will be maintained in BTCEVTJOB table.In our Zprogram we have to call the function module BP_EVENT_RAISE , so that the job status is checked and if it is not executed then the linked event is raised and the job is executed ( Our 1st Zprogram which is defined for the second job should have this logic).Then the second Zprogram should have the logic for creating physical idocs from file and for posting the application data.

Hope this clear. If any doubts , specify.

Read only

Former Member
0 Likes
975

hi

MASTER_IDOC_DISTRIBUTE fm is used to create a IDOC for outbound & for inbound

try this

you can use master_ale_distribute function module to create the idoc.but before that you need to populate two internal table to pass in to this function module.

1.it_edidc = this internal table tells the port,partner profile etc.this internal table having the same structure of edidc table

2,second you create the internal table conatains the data records.this table got the the structure of edid4.

3.populate these two internal table and pass this to this function module

4.you can populate the second internal table from your flat file by writing some upload program

FORM master_ale_distribute .

*PERFORM get_mestype.

wa_edidc-mestyp = wrk_mestyp.

wa_edidc-idoctp = wrk_idoctyp.

CALL FUNCTION 'MASTER_IDOC_DISTRIBUTE'

EXPORTING

master_idoc_control = wa_edidc

  • OBJ_TYPE = ''

  • CHNUM = ''

TABLES

communication_idoc_control = it_edidc

master_idoc_data = it_idoc_data.

IF sy-subrc 0.

ELSE.

READ TABLE it_edidc INTO wa_edidc INDEX 1.

IF sy-subrc = 0.

MESSAGE s006(msg) WITH wa_edidc-docnum.

PERFORM modify_idocnum.

ENDIF.

ENDIF.

ENDFORM.

Regards