Additional Blogs by Members
cancel
Showing results for 
Search instead for 
Did you mean: 
STALANKI
Active Contributor

I have a simple requirement for transforming the source interface format to the destination interface format. I don’t like to use Java or XSLT or ABAP mapping for such a simple requirement. I can use the graphical mapping editor but don’t prefer to, as it is not very friendly with me.
Let me explain before I confuse! Let me show the sample source XSD and destination XSD.

Let me explain the transformation logic. All the elements of node (source) should be mapped to the text field (destination) separated by comma. I can do it using the “concat” function or write my own advanced user defined function in the message-mapping editor. It looks very easy.

The problem is that “concat” function takes two parameters and we have to explicitly map all the elements of source node to the destination text field. I have mapped for just 4 fields and have a look at the maze formed. Imagine it when I map all fields.

User-Defined function simplifies maze to an extent but it can accept only 9 parameters. Imagine the mapping exercise for 9 parameters if the advanced function looks like as shown below:

What if source node has 40 elements and there are 10 such nodes which has to be mapped? Can you imagine the complex maze and pain using the mapping editor for this? This kind of scenarios is very frequent when we need to transform idoc structures to flat files or send the idocs in mails!
Why cannot we have facility to pass the node to some complex functions (May be one more type of functions that can be provided by SAP) and provide the data structure for manipulating the children of the source node, which can be mapped to the target node? And also if we have the facility to generate the target xml for an intermediate node of the source interface and target interface that will be helpful for XI developers.
Let me explain the expectations.

Complex Function 1:It takes the node “Order” as an input and provides a data structure, which can access the children of the “Order” and XI developer writes a small code for comma separation and generate the target element. Does it not make XI developers life easier? This complex functions should be provided global access if we need to reuse it any other message mapping.

One more recommendation is to provide the re-name option for design objects. Once the object is re-named all the dependent objects have to be reflected with the same. Let me come to the context of message mapping and explain the difficulty that is faced due to the lack of that feature. I have one sample user defined function, which is used for mapping idoc to target structure. It is used on every field of the source idoc structure. After development is over and tested there are few changes in the business for which for some fields I need to add one more parameter as input and modify the logic of the user-defined function. It provides me an option to edit the logic but cannot change the definition part of it due to which I have to write a new user defined function and re-do the whole mapping exercise. It would have been better if we a have option of specifying the optional parameters and required parameters and also provision of changing the definition after the user defined function is created.

“I like working with XI but if some small things like this are taken into consideration it can turn out to be much more powerful tool”-XI developers. I listed just few of the common mapping problems that are encountered. More Ideas can be contributed for enhancing the editor.Does every one agree with me?

15 Comments