cancel
Showing results for 
Search instead for 
Did you mean: 

Runtime Error............pls help...........

Former Member
0 Kudos

Hi,

My scenario is like that R/3 and SMIS systems ae sending acknowledgement files to FTP in a folder. XI has to pick all the files from FTP and has to post to ORACLE by using JDBC adapter.There is a particular format based on that we need to map between the xmls and the structure.

I have created the structure in Data Type. But I am getting an error as below:-

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

- <!-- Request Message Mapping

-->

- <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/_ACK_MDM_RM_MM_</SAP:P1>

<SAP:P2>com.sap.aii.utilxi.misc.api.BaseRuntimeException</SAP:P2>

<SAP:P3>RuntimeException in Message-Mapping transformatio~</SAP:P3>

<SAP:P4 />

<SAP:AdditionalText />

<SAP:ApplicationFaultMessage namespace="" />

<SAP:Stack>com.sap.aii.utilxi.misc.api.BaseRuntimeException thrown during application mapping com/sap/xi/tf/_ACK_MDM_RM_MM_: RuntimeException in Message-Mapping transformatio~</SAP:Stack>

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

</SAP:Error>

I am sending the incoming xml formats also. from R/3 here is the format:-

- <ZTVCMSEG SEGMENT="1">

<ZGLBID>10012</ZGLBID>

<ZLOCID>NULL</ZLOCID>

<ZOBJECT>CUSTOMER</ZOBJECT>

<ZCLIENTSYSTEM>CBS</ZCLIENTSYSTEM>

<ZREASON>Atleast One Selling BU Is Mandatory</ZREASON>

<ZDISTIME>20070831 083432</ZDISTIME>

<ZSTATUS>FAILED</ZSTATUS>

</ZTVCMSEG>

<ZTVCMSEG SEGMENT="1">

<ZGLBID>230677</ZGLBID>

<ZLOCID>0000100295</ZLOCID>

<ZOBJECT>CUSTOMER</ZOBJECT>

<ZCLIENTSYSTEM>CBS</ZCLIENTSYSTEM>

<ZREASON>11680101</ZREASON>

<ZDISTIME>20070831 083519</ZDISTIME>

<ZSTATUS>SUCCESS</ZSTATUS>

</ZTVCMSEG>

The problem is in ZLOCID (I think) and the xml coming from SMIS is:-

<ROWSET>

- <ROW>

<ID>1234567890</ID>

<GLOBALID>1000001</GLOBALID>

<LOCALID>3456789012</LOCALID>

<OBJECT>Customer</OBJECT>

<CLIENTSYSTEM>SMIS</CLIENTSYSTEM>

<ERRORMESSAGE />

<DISTRIBUTEDTIME>06/28/2007 15:29:10 GMT</DISTRIBUTEDTIME>

<STATUS>OK</STATUS>

</ROW>

</ROWSET>

And the database for mat is:-

GLOBALID NUMBER Yes - -

LOCALID NUMBER Yes - -

OBJECT VARCHAR2(500) Yes - -

CLIENTSYSTEM VARCHAR2(500) Yes - -

ERRORMESSAGE VARCHAR2(500) Yes - -

DISTRIBUTEDTIME TIMESTAMP(2) Yes - -

STATUS VARCHAR2(50) Yes - -

Please advice me how to map it.

Best regards

Soumya

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Let me try to understand u r scenario first:

you have two different input structure one from r/3 and the other from SMIS and you are have to insert both these into oracle database.

If this is the scenario, then are you using 2 different mappings, one from R/3 to Oracle and another one SMIS to Oracle Or are you using multi mapping.

if its the 1st case then we need figure out which of one the two mappings is actually failing and then we can try to correct that one.

you can first test your mappings individually in the message mapping -- > test tab --> enter the values and click on execute > check the output (incase it fails then you will get a detailed error message) > also use the display queue option to further analyse it.

Cheer's

Former Member
0 Kudos

Hi,

there is no error in test.It is saying executed successful. Here is the error in java in sxmb_moni:-

Cannot produce target element /ns0:ACK_RM_MT/RECORD. Check xml instance is valid for source xsd and target-field mapping fulfills requirements of target xsd at com.sap.aii.mappingtool.tf3.AMappingProgram.start

I am using only one mapping...since the target structure is same for both the incoming xmls.

pls advice what to do.

Soumya

Former Member
0 Kudos

How are you mapping the "record" node/element in the target structure.

Former Member
0 Kudos

do the node to node mapping.. I think in your target RECORD is optional node and you have not map it with source field.. if it is optional map it to root node of the source data..

first map root node of source xml to RECORD node of target and then test the result..

Former Member
0 Kudos

it would be great if u could paste the source and target xml structure.. in the forum...

Former Member
0 Kudos

Hi,

Here is the source xml structure:-

- <ZTVCMSEG SEGMENT="1">

<ZGLBID>10012</ZGLBID>

<ZLOCID>NULL</ZLOCID>

<ZOBJECT>CUSTOMER</ZOBJECT>

<ZCLIENTSYSTEM>CBS</ZCLIENTSYSTEM>

<ZREASON>Atleast One Selling BU Is Mandatory</ZREASON>

<ZDISTIME>20070831 083432</ZDISTIME>

<ZSTATUS>FAILED</ZSTATUS>

</ZTVCMSEG>

- <ZTVCMSEG SEGMENT="1">

<ZGLBID>230677</ZGLBID>

<ZLOCID>0000100295</ZLOCID>

<ZOBJECT>CUSTOMER</ZOBJECT>

<ZCLIENTSYSTEM>CBS</ZCLIENTSYSTEM>

<ZREASON>11680101</ZREASON>

<ZDISTIME>20070831 083519</ZDISTIME>

<ZSTATUS>SUCCESS</ZSTATUS>

</ZTVCMSEG>

(Only 1st one is the source xml structure. 2nd one is the same.....I have posted the same with example as you can see the values for ZLOCID are different in the aboce two cases in the same xml structure.)

And here is the target xml structure:-

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

<xsd:schema targetNamespace="http://ericsson.com/xi/MDM" xmlns="http://ericsson.com/xi/MDM" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><xsd:element name="ACK_RM_MT" type="ACK_RM_DT" /><xsd:complexType name="ACK_RM_DT"><xsd:annotation><xsd:appinfo source="http://sap.com/xi/TextID">0ed9df4059e311dccf6f000f203cb2ba</xsd:appinfo></xsd:annotation><xsd:sequence><xsd:element name="RECORD"><xsd:annotation><xsd:appinfo source="http://sap.com/xi/TextID">f7b1da00516f11dc89b5000d60a4da77</xsd:appinfo></xsd:annotation><xsd:complexType><xsd:sequence><xsd:element name="ACTION" type="xsd:string"><xsd:annotation><xsd:appinfo source="http://sap.com/xi/TextID">f7b1da01516f11dc9906000d60a4da77</xsd:appinfo></xsd:annotation></xsd:element><xsd:element name="TABLE" type="xsd:string"><xsd:annotation><xsd:appinfo source="http://sap.com/xi/TextID">f7b1da02516f11dc8d62000d60a4da77</xsd:appinfo></xsd:annotation></xsd:element><xsd:element name="DATA" maxOccurs="99999999"><xsd:annotation><xsd:appinfo source="http://sap.com/xi/TextID">f7b1da03516f11dca1b9000d60a4da77</xsd:appinfo></xsd:annotation><xsd:complexType><xsd:sequence><xsd:element name="GLOBALID" type="xsd:integer" minOccurs="0" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><xsd:annotation><xsd:appinfo source="http://sap.com/xi/TextID">f7b1da04516f11dcced7000d60a4da77</xsd:appinfo></xsd:annotation></xsd:element><xsd:element name="LOCALID" type="xsd:string" minOccurs="0" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><xsd:annotation><xsd:appinfo source="http://sap.com/xi/TextID">f7b1da05516f11dc9e0c000d60a4da77</xsd:appinfo></xsd:annotation></xsd:element><xsd:element name="OBJECT" type="xsd:string" minOccurs="0" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><xsd:annotation><xsd:appinfo source="http://sap.com/xi/TextID">f7b1da06516f11dcc6d2000d60a4da77</xsd:appinfo></xsd:annotation></xsd:element><xsd:element name="CLIENTSYSTEM" type="xsd:string" minOccurs="0" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><xsd:annotation><xsd:appinfo source="http://sap.com/xi/TextID">f7b1da07516f11dca7b8000d60a4da77</xsd:appinfo></xsd:annotation></xsd:element><xsd:element name="ERRORMESSAGE" type="xsd:string" minOccurs="0" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><xsd:annotation><xsd:appinfo source="http://sap.com/xi/TextID">f7b1da08516f11dccb3a000d60a4da77</xsd:appinfo></xsd:annotation></xsd:element><xsd:element name="DISTRIBUTEDTIME" type="xsd:string" minOccurs="0" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><xsd:annotation><xsd:appinfo source="http://sap.com/xi/TextID">f7b1da09516f11dcbe39000d60a4da77</xsd:appinfo></xsd:annotation></xsd:element><xsd:element name="STATUS" type="xsd:string" minOccurs="0" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><xsd:annotation><xsd:appinfo source="http://sap.com/xi/TextID">f7b1da0a516f11dcc5ae000d60a4da77</xsd:appinfo></xsd:annotation></xsd:element></xsd:sequence></xsd:complexType></xsd:element></xsd:sequence></xsd:complexType></xsd:element></xsd:sequence></xsd:complexType></xsd:schema>

How to do the mapping...pls reply.....i tried but still it is giving the following error in trace in java:-

com.sap.aii.utilxi.misc.api.BaseRuntimeException: RuntimeException in Message-Mapping transformation: Cannot produce target element /ns0:ACK_RM_MT/RECORD. Check xml instance is valid for source xsd and target-field mapping fulfills requirements of target xsd at com.sap.aii.mappingtool.tf3.AMappingProgram.start

Answers (2)

Answers (2)

Former Member
0 Kudos

to make your job easier, select 'Trace' of the request message mapping pipeline servive and search for 'java'.. there you will get detailed description about the error.

Former Member
0 Kudos

Hi Soumya,

First test the message mapping locally in IR. Change the trace level to 'Debug' and run the mapping.

read the trace message and find out where exactly is the error.

In SXMB_MONI, you must have got 'java stack' of the error. Look at it instead of on e you have pasted here..

Ranjeet.