![]() If you require further guidelines on how to define and configure variables, refer to this help document: ![]() In my case, the result full file path was: You could use the following configuration to dynamically set target directory and file name: This gives you quite a lot of possiblities to create the file name that you need.įor example, let us assume that you need to use the customer number as a file name part for a customer master data scenario, and the name of the interface as the directory (to match the company's general naming convention policy). On the other hand, the payload-based variables let you get access to the contents of the message that is delivered to the receiver, with some kind of a query that you define in the variable definition. In header attributes, you can for instance get access to the sender & receiver service, interface name or message ID. There are two types of variables you can define: connected to message header attributes, and payload-based. The idea is simple here: in the Variable Substitution on the Advanced tab page, you define some variables that you later use in Target Directory or File Name Scheme on the Target tab page. This is another capability of the receiver file Communication Channel that you might use to influence the file name or path under which the file is generated. Pros and cons: + The easiest implementation of all possible options, - Limited options to influence the file name, - No flexibility. Refer here for configuration details: Įxample filenames: xi_output_20120213-180304-425.xml (with xi_output_.xml and Add Time Stamp) xi_output_005056a4-7bae-1ee1-95df-3964c12edd64.xml (with xi_output_.xml and Add Message ID) xi_output_0002.xml (xi_output_.xml and Add Counter) This is only possible with the NFS Transport Protocol. Following rules apply:Īdd Time Stamp: the time stamp is added as the last part of the name, directly before the extension, and it is always formatted yyyyMMdd-HHmmss-SSS.Īdd Message ID: PI’s message ID is added to the file name, formatted as xxxxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx.Īdd Counter: a consecutive number is added to the file name, directly before the extension. However, you cannot influence the way the dynamic part of the file name is generated. As of SAP Help description, this was originally designed to guarantee that no file is overwritten, but you could possibly also use it for some business requirements. The last three of them lead to the file name being generated dynamically. You have the following options for File Construction Mode: Create, Append, Add Time Stamp, Add Message ID, and Add Counter (only for NFS Transport Protocol). You can find the respective option in the Processing tab page of your receiver file Communication Channel. This is by far the simplest solution, and it can only match the simplest requirements. Running OS command after message processing.Adapter-Specific Message Attributes (and Dynamic Configuration),.File Construction Mode in Communication Channel parameters,. ![]() The options available are as follows, in the order of preference (with a recommendation to use the upper-most one on the list that matches your requirements): For this reason, I have decided to provide a summary of available options, with some configuration guidelines and a list of pros and cons for each option. Many questions arise in the SDN Forum about how to dynamically generate the file name or target directory in the Receiver File Adapter, for some particular requirements. I would even say more: there are two ways to achieve this, both having some strong and weak sides, and it is up to you to decide which one matches your requirements better. You can stay with SAP standard AND enable monitoring at the same time, for standard BAPI scenarios. Moreover, I found out in SDN Forums that I was not the only one to face this dilemma.īut I am happy to announce to all of you that there is a way to have your cake and eat the cake. And on the other hand, I would be glad to stay with pure SAP standard functionality, for support reasons. The reason was that I have found a BAPI that perfectly matched my requirements, but did not want to go for a BAPI-RFC scenario, because of no monitoring available in the backend system. So many times I felt like I was between a rock and a hard place, when developing an integration scenario.
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |