My previous post discussed the “hidden” menu in the SAP PI message mapping tool that can only be unlocked by pressing <Ctrl> + <Shift> while right clicking in the data flow editor area. Hands down, the best feature of this menu is the import/export functionality. I have no idea why the SAP developers buried such a useful feature in such a hard-to-find menu. Whatever the reason, now that we know that we can import and export message mappings, we can exploit this fact to make our map-developing lives easier.
Most SAP PI developers have had a situation where a relatively minor change to the target message causes real havoc to the entire message mapping. For relatively small maps, it may not be a big deal. For maps with complex logic, this can be a big deal requiring hours of tedious rework. Recently, I was faced with a requirement change that required my message mapping to change correlations from 1:1 to 1:N. Since this interface used the RFC adapter (which supports multiple messages), I was able to implement a 1:N multi-mapping message split. In the new interface design, the file adapter will process one file and pass it to the integration engine. The integration engine will perform a multi-mapping message split to break-up the message. The new, individual messages will be sent via one adapter engine call to the RFC adapter. The RFC adapter will handle each message individually, calling each in a separate logical unit of work (LUW).
The steps below will detail how to switch a message mapping from a 1:1 correlation to a 1:N correlation without remapping anything!
[Read more...]







