|
Home > Archive > BizTalk Server Orchestration > May 2006 > How to map elements from different levels?
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
How to map elements from different levels?
|
|
| Bambitroll 2006-05-29, 5:21 pm |
| I have to map 2 elements which are not at the same level in the 2 XSD
files.
The incoming XSD (A) looks like this:
Level1
....Level2
.......Element1
.......Element2
The outgoing XSD (B) is like this:
Level1
....Level2
.......Level 3
..........Element1
..........Element2
So as you can see, the end structure is the same but there is one more
level.
My problem is that if I map A.element1 to B.element1 and A.element2 to
B.element2
I get all in only one Level3 element like this:
<Level1>
....<ns0:ListOfScheme>
.......<ns0:Scheme>
..........<ns0:Name>101</ns0:Name>
..........<ns0:Name>202</ns0:Name>
..........<ns0:ManHourRate>100</ns0:ManHourRate>
..........<ns0:ManHourRate>200</ns0:ManHourRate>
.......</ns0:Scheme>
....</ns0:ListOfScheme>
</Level1>
Instead of what I want which is this:
<Level1>
....<ns0:ListOfScheme>
.......<ns0:Scheme>
..........<ns0:Name>101</ns0:Name>
..........<ns0:ManHourRate>100</ns0:ManHourRate>
.......</ns0:Scheme>
.......<ns0:Scheme>
..........<ns0:Name>202</ns0:Name>
..........<ns0:ManHourRate>200</ns0:ManHourRate>
.......</ns0:Scheme>
....</ns0:ListOfScheme>
</Level1>
Do you have any ideas/hints how I could make this work, or even if it
is possible at all?
Thx a lot!
| |
| Bambitroll 2006-05-30, 7:15 am |
| Don't bother, I think I found the answer to this one...
It looks like if I change the XSD and play around a bit with the "Group
Max Occurs" for the receiving element and set it to 1, it forces the
mapper to generate one Level 3 entry each time I have new element1&2
BT.
Bambitroll wrote:
> I have to map 2 elements which are not at the same level in the 2 XSD
> files.
> The incoming XSD (A) looks like this:
> Level1
> ...Level2
> ......Element1
> ......Element2
>
> The outgoing XSD (B) is like this:
> Level1
> ...Level2
> ......Level 3
> .........Element1
> .........Element2
>
>
> So as you can see, the end structure is the same but there is one more
> level.
> My problem is that if I map A.element1 to B.element1 and A.element2 to
> B.element2
> I get all in only one Level3 element like this:
> <Level1>
> ...<ns0:ListOfScheme>
> ......<ns0:Scheme>
> .........<ns0:Name>101</ns0:Name>
> .........<ns0:Name>202</ns0:Name>
> .........<ns0:ManHourRate>100</ns0:ManHourRate>
> .........<ns0:ManHourRate>200</ns0:ManHourRate>
> ......</ns0:Scheme>
> ...</ns0:ListOfScheme>
> </Level1>
>
> Instead of what I want which is this:
> <Level1>
> ...<ns0:ListOfScheme>
> ......<ns0:Scheme>
> .........<ns0:Name>101</ns0:Name>
> .........<ns0:ManHourRate>100</ns0:ManHourRate>
> ......</ns0:Scheme>
> ......<ns0:Scheme>
> .........<ns0:Name>202</ns0:Name>
> .........<ns0:ManHourRate>200</ns0:ManHourRate>
> ......</ns0:Scheme>
> ...</ns0:ListOfScheme>
> </Level1>
>
>
> Do you have any ideas/hints how I could make this work, or even if it
> is possible at all?
>
> Thx a lot!
|
|
|
|
|