cancel
Showing results for 
Search instead for 
Did you mean: 

XML message mapping issue!!

Former Member
0 Kudos

Hi ipbuff,

Many Thanks for your very quick reply. I have tried the way what explain, but not working . I am attaching both the structures, please guys throw your valuable openions and technical ways how to resolve this. I have 5 segments in Header, more than Lin item repeats more than 50 times. How do I map DTM Segment, <DTM_Y2K_DATE>20100531</DTM_Y2K_DATE> value for all target side node <ProductActivityNotification>ProductActitvity>Item>SalesTimeSeries>Item>Validate-->StartDate field.

This filed generates the same amount of lIn item generates.

Please your quick response.

I will really appreciate your quick and positive response.

http://img837.imageshack.us/img837/7786/mappinghelp.jpg

Many Thanks

Kind Regars

San

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Sandhya,

I have 5 segments in Header, more than Lin item repeats more than 50 times. How do I map DTM Segment, <DTM_Y2K_DATE>20100531</DTM_Y2K_DATE> value for all target side node <ProductActivityNotification>ProductActitvity>Item>SalesTimeSeries>Item>Validate-->StartDate field

Upto my understanding, u want to map <DTM_Y2K_DATE>20100531</DTM_Y2K_DATE> to StartDate(as above mentioned path).

Since u have 50 occurences for <DTM_Y2K_DATE>20100531</DTM_Y2K_DATE> parent node, but in target its not..... am i rt?

If yes..

Map from <DTM_Y2K_DATE>20100531</DTM_Y2K_DATE> to StartDate, and u also add a node function collapse contexts.

Collapse context will give the very first value in every context.

<DTM_Y2K_DATE>20100531</DTM_Y2K_DATE> > Collapse Context>StartDate.

I think this should solve ur problem.

If still not let us know...

Babu

Former Member
0 Kudos

Hi Babu,

I am sorry may be my question is wrong. Source side xml message has got header with 5 tags, one of the tag is DTM. This comes only once per message, this message has got lin item it occurs more than 50 times. Target side Item tag has to replicate the same 50 times as what source lin tag does. This DTM tag value has to map 50 times to ProductActivityNotification>ProductAcitivity>ITem(this occurs 50 times like Source Lin tag)>SalesTimeSeries>item>ValidPeriod>Startdate field.

Sorry I can't able to present in a proper way.

Many Thanks

Kind Regards

San

Former Member
0 Kudos

Hi,

Ok then current understanding is that,

U have LinItem in source which occurce 50 times in source.

U want to create 50 times the Line item in target also.

But in target u want this DTM_Y2K_DATE also mapped every time....

If it is the requirement then go for UseoneAsMany.

3 arguments for this.

1. give DTM_Y2K_DATE

2. give LinItem (from source)

3. Give any field within in the Line item of source (Child node)

Map this to LineItem node also the start date of target.

Let us know the result...

Babu

Former Member
0 Kudos

Hi Babu,

Many thanks for your quick response will you please have a look the foillowing link, it shows message structures. Then please guide me.

http://img837.imageshack.us/img837/7786/mappinghelp.jpg

Regards

San

Former Member
0 Kudos

Hi San,

I have seen the link of of your mapping image already..

Did u tried by using one as many... it should work...

Or still i am nt understaing the requirements???

Babu

Former Member
0 Kudos

Hi Babu,

I am not able to get with useoneAsmany function. Can you please you have seen my source message and target message structure, Could you please give which fields and which tags I have to connect UseoneASmany function to target.

Kind Regards

San

Former Member
0 Kudos

Hi,

Ok lemme clarify this last point.. then il tell u with the field names u shold use for use one as many....

U want to map DTM_Y2K_DATE to StartDateTime.

As many Group_LIN we have in source we have to create that many Item(Node) in target rt?

Also for all these Item in target u want to map the DTM_Y2K_DATE field.

Is my understaing rt??

If not now explain with the fields...

Babu

Former Member
0 Kudos

Yes, You are correct babu. Please guide me now.

Cheers

San

Former Member
0 Kudos

Hi San,

Ok now map like this... for both the fields(Item node, StartDateTime field)

1.Item node

In useOneAsMany we have three inputs.

give the argumnets like this...

first argument DTM_Y2K_DATE

Second Argument Group_LIN

third argument any field in the Group_LIN node..(i could not c any field in the Group_LIN node..)

Now map the o/p of useOneAsMany to the target node Item

2.StartDateTime field

Map DTM_Y2K_DATE to StartDateTime

If still prblm exists let us know..

Babu

Former Member
0 Kudos

Hi Babu,

Many thanks for your very quick response. I have mapped with UseoneAsmany function, in item node (target side) date is replicating. I mapped date field to start date. But while producing the target, first two item elements comes with start date, from 3rd item node there is no start date field under SalesTimeSeries>Item>ValidityPeriod-->Startdate.

In source message I am getting 2 <OUTPUT> tags so it is passing that date into 2 Item target segments.

Please have a look screen shot. But the way you explaing very excellent.

http://img839.imageshack.us/img839/8778/mappingerror3.jpg

Kind Regards

San

Former Member
0 Kudos

Hi Babu,

Problem resolved.

Many Thanks

Points alloted.

Regards

San

Answers (0)