cancel
Showing results for 
Search instead for 
Did you mean: 

Very Interesting Mapping problem

Former Member
0 Kudos

Hi all,

I am getting a mapping error. When I am testing the values in Mapping. I am facing a very interesting problem. When I switch to the Test tab and I enter values into the respective fields of the interface mapping. and then do Execute Mapping goes successfully. But when I load the xml which I copied to a file from the SXMB_MONI it gives an exception when I do a mapping. Infact if I go to Source view and copy the XML it says the XML is not well formed. What is going on and anybody knows how to rectify the situation. Please help. Here are both the XMLs

Good XML

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

<ns:mt_sender1 xmlns:ns="http://xml2xml">

<PONO>12</PONO>

<POQTY>90</POQTY>

<POAMT>20</POAMT>

</ns:mt_sender1>

Bad XML

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

- <ns:mt_sender xmlns:ns="http://xml2xml">

<PONUM>25</PONUM>

<POQTY>12</POQTY>

<POAMT>35.67</POAMT>

</ns:mt_sender>

On further investigation I found that the first should be

<?xml version="1.0" encoding="UTF-8" ?> without a spce so how do we configure that.

Accepted Solutions (0)

Answers (7)

Answers (7)

Former Member
0 Kudos

Hey Sonia,

Your configuration is wrong..

Why the namespace is diff i.e in good xml it is mt_sender1 & in bad xml it is

mt_sender. Please correct the namespace. You can correct name space in Message type. If not required then remove it from structure.

Secondly your field names should also be same not as PONUM & PONO.

Regards

Sushil

Former Member
0 Kudos

Hi,

The problem is indeed that you select the contents of one of the screens in sxmb_moni and copy that into the Integration Builder. This includes the '-' signs.

Instead, right-click the xml you see, select 'View Source' and copy the contents from there.

Kind regards,

Koen

Former Member
0 Kudos

Sonia,

Use the Export XML or Download option in MONI. Donot Copy,paste the XML from MONI Screen and Test Your Mapping.

Regards,

Sudharshan

Former Member
0 Kudos

Bad XML

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

- <ns:mt_sender xmlns:ns="http://xml2xml">

<PONUM>25</PONUM>

<POQTY>12</POQTY>

<POAMT>35.67</POAMT>

</ns:mt_sender>

this XML is not valid as u can see there is a '-' sign there

Former Member
0 Kudos

hey

the problem is - in - <ns:mt_sender xmlns:ns="http://xml2xml">

u can't copy payload like this from MONI,u have to right click and hit source view,and then use that XML to test in IR,also change PONO to POTNUM,u cant have data type like this

thanx

ahmad

Message was edited by:

Ahmad

Former Member
0 Kudos

Hi Sonia,

Just remove - sign from the below line in bad xml.

- <ns:mt_sender xmlns:ns="http://xml2xml">

Thanks

Balaji

Former Member
0 Kudos

Sonia,

2 corrections.

1. <b><PONUM>25</PONUM></b>. If your sender sends it as PONUM, then change the source data type also to PONUM istead od PONO.

2. While copying the contenet from SXMB_MONI, you need to do 2 things.

a.Remove the <b>+</b> sign in the XML.

b. Remove any space <b>before</b> the first line <b><?xml version="1.0" encoding="UTF-8" ?></b>

Regards,

Jai Shankar