cancel
Showing results for 
Search instead for 
Did you mean: 

External Defintion used for IDOC in Operations Mapping results in Error

Former Member
0 Kudos

Hi everyone,

I ran into an odd situation with a client that I want to run by the group.

We had an interface that was SOAP to IDOC.  The original interface was created over a year ago and the original developer then updated that interface by changing the IDOC from a 1 to 1 to 1 to unbounded so 1 message creates multiple IDOC's which we all know is very starndard in PI.

They changed the mapping to use the external definition which is correct.  However they created a service interface using the external definition(not IDOC) and used the service interface in the operation mapping which is wrong and will result in errors when creating the IDOC.  All the standards posted on this scenario indicate the Service Interface is not needed and in the Operation Mapping the receiver needs to be the IDOC(not external definition).  I believe you can use the SI as long as it points to the IDOC and not the external definition as well(never tried it).

The problem was the developer DID NOT update the ICO(integration configuration object) in the ID.  It was still showing the IDOC(prior to changing to external definition) so the interface was working.

Long story here but we had to do manual transport to another environment and we updated the ICO by reselecting the OM and now the ICO is seeing the Service Interface(external definition) instead of the IDOC.  Hence we started getting the error shown below and that was when I discovered everything mentioned above.

I changed the interface by deleing the Service interface and using the IDOC directly in the Operation Mapping which is well documented and we all know its works and it resolved the problem and the IDOC's started posting with no issues.

The problem was no one on the PMO teamed believed that the interface had a problem because it was working in 2 other QA environments and wanted an explanation which I provided.  Long story but it created a huge issue with the other developer who refused to acknowledge the problem.

QUESTION - I'm looking for other PI developers to comment on the standard process to change an IDOC from 1 to 1 to 1 to unbounded and let me know if I'm missing anything here.  Several documents and posts on this scenario.  Thanks and I appreciate your feedback.

Error when using the external definition in the Operation mapping when target is IDOC:

Adding control record to payload failed due to Error during
transform: java.lang.NullPointerException: while trying to invoke the method
java.lang.String.length() of a null object loaded from local variable chars

MP: exception caught with cause com.sap.aii.af.idoc.exception.IDOCAdapterException:
Error during transform: java.lang.NullPointerException: while trying to invoke
the method java.lang.String.length() of a null object loaded from local
variable 'chars'

Accepted Solutions (0)

Answers (2)

Answers (2)

former_member184876
Active Participant
0 Kudos

Hi Steve,

This is a standard process. Please find the below good blog from Michal on this.

Also the SAP note

814393 - Multiple IDoc instances in an XI message

Thanks,

Venu

Muniyappan
Active Contributor
0 Kudos

Hi,

it is just change in external definition and message mapping.