cancel
Showing results for 
Search instead for 
Did you mean: 

Mapping will not work

Former Member
0 Kudos

Dear all,

I am trying to use the graphical mapping tool for a task that looks quite simple, but I do not suceed. I have two very similar structures (please see below) which basically only differ in an constant value in target structure.

Can you please help, I already tried to adjust communalities (all items are (0...1) and the repeating structure <G1> and <item> are defined as (0...unbounded)), all field tapes are string.

I will appreciate any hints.

Best regards

Acram

This ist the initial structure:

<Message_Type_File_Upload>

<DatenTypFlach>

<G1>

<F1>Key Field</F1>

<F2>Date</F2>

<F3>Servername</F3>

<F4>PercentageF4>

</G1>

<G1>

<F1>Key Field</F1>

<F2>Date</F2>

<F3>Servername</F3>

<F4>PercentageF4>

</G1>

.....

</DatenTypFlach>

</Message_Type_File_Upload>

and I am trying to map it to this structure:

<Target_Structure>

<DATASOURCE>this is the constant value</DATASOURCE>

<DATA>

<item>

<ZKEYFIELD> </ZKEYFIELD>

<ZDATTE> </ZDATTE>

<ZSERVERNAME> </ZSERVERNAME>

<ZPERCENTAGE> </ZPERCENTAGE>

</item>

<item>

<ZKEYFIELD> </ZKEYFIELD>

<ZDATTE> </ZDATTE>

<ZSERVERNAME> </ZSERVERNAME>

<ZPERCENTAGE> </ZPERCENTAGE>

</item>

.....

</DATA>

</Target_Structure>

Accepted Solutions (0)

Answers (7)

Answers (7)

Former Member
0 Kudos

just wanted to assign reward points correctly

Former Member
0 Kudos

Dear all,

a lot of hints, I now tried again and mapped each field of the initial structure to the fields in the target structure- I also tried all possible combinations, but still only the constant values are shown in the test environment.

I think the problem is more likely in the structure or deals with cardinalities or communalities. When display the queue for each mapped field I either get SUPPRESS entries or empty queues.

Best regards

Acram

Former Member
0 Kudos

can u send me screen shot of our mapping. mail to sreeram.g.reddy@gmail.com

Thanks

Sreeram.G.Reddy

prabhu_s2
Active Contributor
0 Kudos

can u send across the xml payload?

Former Member
0 Kudos

Dear Prabhu, Dear Sreeram,

mail was sent. thank you again

prabhu_s2
Active Contributor
0 Kudos

okie can u map the <b>message_type_file_used</b> of source to <b>_-bio_-*</b> i.e. the header of target and check

Former Member
0 Kudos

I did not get the mail. sreeram.g.reddy@gmail.com

Former Member
0 Kudos

I did so before and get this error message:

Cannot produce target element /ns1:_-BI0_-QI6AZBKKS_IS_B_ERV__1_RFC. Check xml instance is valid for source xsd and target-field mapping fulfills requirements of target xsd

Former Member
0 Kudos

can you check our input XML from SXMB_moni and XML in our mapping. both are not same. can you confrim me . both should be same except the data .

Thanks

Sreeram.G.Reddy

Former Member
0 Kudos

I checked the structure from the payload and the structure used on the input side of the mapping and it looks quite the same to me.

I only had to rename some of the tags as the Orginal H1 tag lead to formatting problems in the forum

Former Member
0 Kudos

can you paste the both xml

Former Member
0 Kudos

I have done it via Mail because within the forum it will all be displayed in huge characters <H1>Tag will not work</H1> (This is what happens if I use the H1 tag)

Former Member
0 Kudos

I just got your mail . the error is you have tag named RecordSet.

It is RecordSet in ampping and in XMl it is </Recordset> difference it small set small 's' in set. please change this.

Thanks

Sreeram.G.Reddy

Former Member
0 Kudos

I now changed Recordset into RecordSet, the Result is the same in the test environment as well as in the whole process. Only the constant value is mapped and all other fields are ignored.

Message was edited by:

Acram Shendi

Former Member
0 Kudos

you need to change it in mapping in mapping make it has Recordset. because in XML your getting as Recordset .

Thanks

Sreeram.G.Reddy

Former Member
0 Kudos

Dear Sreeram,

I changed it in the XML as well in the test file as in the generated file from the file adapter, so the mapping now receives a RecordSet instead of a Recorset.

Former Member
0 Kudos

Make the change in file adapter and activate the changes in file adapter . and put the file. if you did not get send output send the XML of sxmb_moni latest one.

Former Member
0 Kudos

Thank you very much Sreeram, I have done exactly this before. But still no change in the behaviour, only onstants in the results payloads.

Mail was sent.

Former Member
0 Kudos

can u test in test tab by manual entering values in the source this sould create target structure . and send that XML tome . please dont send sxmb_moni XML.

Former Member
0 Kudos

hey our namespace is wrong . please give same name space in file adapter which you created in mapping .

now both are different in mapping you have "http://de.suwag" which different in mapping.

Thanks

Sreeram

Former Member
0 Kudos

Daear Sreeram,

done, mail was sent, could % and " characters cause any problems.

Best regards

Acram

Former Member
0 Kudos

I am not sure if I can do this because the target namespace is SAP generated from a BAPI / Function Module in SAP. Within the test tool nothing happens (same result as before) when I change namespaces in XML

Message was edited by:

Acram Shendi

Former Member
0 Kudos

No your source namespace in mapping different in file dapter is different

Former Member
0 Kudos

Hi Acram,

U have been fighting a lot on this ...

There are already a lot of suggestions for u So I just thought not to suggest but i will share my understanding

The MMapping is a java program which runs from ur Root to the last leaf and compare it with matching target element and insert the value of source to target

using XPATH .

So in ur case all the target structure is getting created (u can check thisin MONI) but the values are not getting copied from source , mean the Mapping program is not getting the path properly ( the BAPI structure is not properly pointed Or the context is not properly !!)

Or the changes ur doing are not getting updated .

If this is the case u can save and activate the mapping and do a test

Regards,

Kavitha

Former Member
0 Kudos

when you paste your XML from SXMB_MONI in test tab of mapping you will be src view can click on tabular tree view then should find some red instead of green.

if you find any red let me know which is that field

Former Member
0 Kudos

@ Sreeram

all of them are red, if I input the data manually the Icons are green but the result will not change...

Former Member
0 Kudos

@ Kavitha

no, the target structure is not getting created, only the mapped constants are created.

Former Member
0 Kudos

if all them red means our source fields in mapping and xml fields name are diffrent .they should be same. canyou tell frist red tag

Former Member
0 Kudos

Acram,

If structure is nt getting created mean for the source element the Corresponding target element position is not matching Bapi seems to be deeply nested

Are there any fields before ur data fields whose occurrence is 1 (mandatory )

Check for mandatory fields in the target if not required supress them

Regards

Kavitha

Former Member
0 Kudos

the structures were send.

Former Member
0 Kudos

can map all constant to target and test it . if you can produce a target as you required.

Former Member
0 Kudos

The problem was caused by a typo in the namespaces within SAP ERP. Thank you very much for your help. Sreeram, do you like Wine?

Best regards

Former Member
0 Kudos

just give points enough we will have wine some other time. time to leave home it is late

Former Member
0 Kudos

Hope now all points are assigned

Former Member
0 Kudos

Hi Arcam,

Please map <DatenTypFlach> to </DATA> and <G1> to <item>.

please reward points

Thanks

Sreeram.G.Reddy

Message was edited by:

Sreeram Reddy

prabhu_s2
Active Contributor
0 Kudos

okie map a constant(c) with no value to <DATASOURCE>

<DatenTypFlach> to <DATA>

<G1> to <item>

<F1> to <ZKEYFIELD>

<F2> to <ZDATTE>

<F3> to <ZSERVERNAME>

<F4> to <ZPERCENTAGE>

Former Member
0 Kudos

Dear all,

I have done all this before and checked again now, but without any result only the constant is displayed in the result area (while using the test tab) and when I test the whole process only the constant value is transferred to the Receiver BAPI.

But thank you all for your answers.

Best regards

Acram

prabhu_s2
Active Contributor
0 Kudos

sorry...it will not have any effect in framing the subnode DATA. If incase DATASOURCE has some subnodes and if not mapped, the subnodes will not be frameds. I didnt notice the end of the tag for DATASOURCE and hence a confusion.

Former Member
0 Kudos

Hi,

Map as per below

G1 (0...unboundde)-> item -(0...unboundde)>

F1 - ZKEYFIELD

F2 - ZDATTE

F3 - ZSERVERNAME

F4 - ZPERCENTAGE

Regards,

Venu.

Former Member
0 Kudos

Dear Mario & Venu,

until now, I mapped the fields at the lowest <F1> to <F4> point of the hierarchy. When I get you right I should map at G1 level.

I will try tihis, but could you shortly explain why ?

Thank you very much for your quick response.

Best regards

Acram

Former Member
0 Kudos

Hi Acram,

imagine the mapping like an "upside down" tree.

The mapping starts at the top of your

target

message und steps down.

If a step down is not possible, e.g. no mapping to source element, it DOES NOT procede with the remaining child elements.

Regards

Message was edited by:

Mario Müller

Former Member
0 Kudos

Dear Mario,

Dear Prabhu,

why do you suggest to map an empty value to my constant. Are there any limitation that will prevent XI from prcessing the items and fields below?

Best regards

Acram

Former Member
0 Kudos

Also map <Message_Type_File_Upload> with <TargetStructure> at the root level and check again. If that doesnt work, please delete that mapping and reccreate the mappings as suggested from scratch.

Former Member
0 Kudos

Hi Acram,

1) after createing a test-message in the test-tab return to the design tab.

If you now display a mapping in the lower area you can right-mouseclick > <b>show queue</b>.

This is a >kind of debugging<

2) sometimes is helps to save your MM and open it again.

Regards Mario

Former Member
0 Kudos

Hi ,

You have to map G1 with Item which are unbounded.Try it now...

Regards,