cancel
Showing results for 
Search instead for 
Did you mean: 

Message Mapping Issues

Former Member
0 Kudos

Hi

I'm mapping a simple source message to a target message which has exactly the same structure.

I'm however receiveing this error in the integration server at runtime:

<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>

- <!-- Message canceled

-->

- <SAP:Error xmlns:SAP="http://sap.com/xi/XI/Message/30" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/" SOAP:mustUnderstand="">

<SAP:Category>Application</SAP:Category>

<SAP:Code area="MAPPING">EXCEPTION_DURING_EXECUTE</SAP:Code>

<SAP:P1>com/sap/xi/tf/_SrctoTarget_</SAP:P1>

<SAP:P2>com.sap.aii.mappingtool.tf7.IllegalInstanceExcepti</SAP:P2>

<SAP:P3>on: Cannot create target element /ns1:SrctoTarget</SAP:P3>

<SAP:P4>S. Values missing in queue context. Target XSD re~</SAP:P4>

<SAP:AdditionalText />

<SAP:Stack>Runtime exception occurred during application mapping com/sap/xi/tf/_SrctoTarget_; com.sap.aii.mappingtool.tf7.IllegalInstanceException: Cannot create target element /ns1:SrctoTarget. Values missing in queue context. Target XSD re~</SAP:Stack>

<SAP:Retry>M</SAP:Retry>

</SAP:Error>

My mapping works fine during design time so i'm not sure whats happening here.

I've had this issue before and solved it by adding a namespace for the document in the file adpater content conversion, but this time its not solving the issue.

Accepted Solutions (1)

Accepted Solutions (1)

former_member200962
Active Contributor
0 Kudos

Hi,

Cannot create target element /ns1:SrctoTarget

In runtime check for the value passed to this element. There is either no or incorrect value passed to this target element.

Regards,

Abhishek.

Former Member
0 Kudos

That is the root node of the xml document.

<ns:SrctoTarget xmlns:ns="urn:xxxxxx-com:i_test">

So it has to be there and there is no value passed to it. Its just mapped to the target root node which is exactly the same

Former Member
0 Kudos

Hi,

Copy the source XML from the SXMB_MONI and past it in the testing tool tab of the message maaping. Execute the test and try to analyse the error by seeing the context.

Regards,

Shweta.

Answers (4)

Answers (4)

Former Member
0 Kudos

Hi

In test test tab after executing the mapping program

go to design and select particular element mapping and view context to see what is source value and target value.check with occurence if it is node to node mapping

rgds

srini

Former Member
0 Kudos

Hi

We've found the problem. It seems that my naming conventions for my interfaces were slightly wrong. They were named very similar names but the case was different so XI was having issues with that. Hard to spot.

Also i needed to specify some extra parameters in my J2SE adapter to correctly identify the document name and namespace.

Tip: Dont copy objects in the Integration Repository, it causes naming issues later on. Always build your objects from scratch. I found that out the hard way.

Thanks for all your help!

Former Member
0 Kudos

If you are using Java mapping.

Test your interface mapping with the payload which failed and check the target xml is getting properly generated,

Former Member
0 Kudos

Hi,

Copy the source XML by clicking on the msg in sxmb_moni and then test it in IR. (mapping test), you should see exactly where the problem is occuring. go to the element and right click on the source and display queue. you will understand where the problem lies.

make that field work by changing the mapping accordingly. you should be good to go.

Regards,

Pavan

Former Member
0 Kudos

Hi,

if the above solution is not working, also check your XSD definition whether it requires element "/ns1:SrctoTarget" to be created (minOccurs="1") although you do not want it to occur in every case.

Regards,

Kai