I must admit that I am not an expert when it comes to IDoc processing. I feel that there is an easy answer to my questions. Here is the scenario:
- From a third party system and via FTP transfer, a flat file is received on the application server.
- The flat file contains non SAP standard data and it does not include any IDoc specifics (control segment, ...). It contains pure business data in the format of the third party system.
- I want to process the flat file via an inbound IDoc based process, thus I intend to create a new IDoc type, message type, ... I think I know all the required steps in order to trigger the process via a function module (WE82, BD51, WE57, WE42, ...) once the true IDoc is there.
My questions are as follows:
- As the flat file is not formatted correctly, I need to do this via a Z-program and schedule it periodically. After formatting, the Z-program could start the IDoc posting process via function module IDOC_INBOUND_SYNCHRONOUS. Is this the way to go respectively would this be the correct way?
- I also read a lot about ports / file ports (WE21). I googled a lot, but unfortunately the purpose of a file port is still not clear to me, especially not in an inbound scenario. What is the purpose of a file port and can it help in my scenario? Would it replace the call of IDOC_INBOUND_SYNCHRONOUS?
Of course it would be possible to handle the described scenario outside of an IDoc process, however I find it very elegant and charming to make use of all the standard functionalities available for IDocs.
Your help is highly appreciated.
Thanks and best regards