Reputation: 301
What is the use of message variant and message function in IDoc partner profile? Which one to be used as per the requirement?
Upvotes: 0
Views: 8170
Reputation: 427
As above mentioned they are key to uniquely identifying a process code/Function Module for processing of the incoming or outgoing IDOCs. A couple of examples are company, plant specific IDOC processing. If you perform any custom processing we can read this value from within a user exit and functions to process differently based on the value.
Its also useful for further selection of IDOCS in reports as shown below.
Note a simple suggestion, define a standard for their use and publish it internally, over time things can get messy.
Upvotes: 2
Reputation: 10621
They are used to differentiate the use-cases of your IDocs.
Each message type means some business function/object, for example ORDRSP
is a purchase order confirmation, and if you wanna use it, for example, for distribution of orders to CRM and SRM systems simultaneously, you can create separate variants (or functions) like this
You can create function CRM with variants 001 and 002 if you have two CRM systems in order to differentiate IDocs in BD87.
Here how it is explained in SAP Help "Inbound Partner Profile":
The message is described by three parameters: The message type is based on EDIFACT message types: for example, a purchase order is of type "ORDERS". You can further subdivide the message type using the message code and function.
Upvotes: 3