Home Page › Forums › BizTalk 2004 – BizTalk 2010 › Re: Re: Basic? Map Question (repeating on left, flat on right)
- This topic has 0 replies, 1 voice, and was last updated 9 years, 10 months ago by
community-content.
-
AuthorPosts
-
-
February 28, 2007 at 8:28 AM #17816
Thanks wa,
I gave it a shot, and I'm getting an error. It's saying that Output validation error Body (the root of the destination) has an invalid child element 'xxx'. List of possible elements expected: 'loveit'
Where "xxx" just happens to be the very next node in my schema past "loveit". I think what's happening is that "loveit" is not getting created when "att1" is not equal to "mostfavorite". Because in reality, the input is really in the opposite order:
<base>
<foo att1="leastfavorite" att2="pear"/>
</base>
<base>
<foo att1="mostfavorite" att2="apple"/>
</base>If I do the if statement, it fails immediately and doesn't create the destination node and I don't think it is automatically looking at the next sibling. How would the input know to loop through all of the <base> nodes? I tried a table loop, but the looping grid doesn't really make anything new I can act on.
Thanks in advance for any more help on this…
Chris
==============================
Chris,
if att1 = "mostfavorite" them map att2 to <loveit>
if att1 = "leastfavorite" them map att2 to <hateit>
use the value mapper and logical test like I showed you earlier
– wa
===============================
Hello All,I have a map. The schema on the left has a repeating node, where the node has two attributes, say "att1" and "att2". Keep in mind that this node only appears once on the left, it just happens to be repeatable. The schema on the right is flat, a bunch of nodes at the same level. I need to map the att2 values to the nodes on the right, but their location is dependant on att1. That is:
On the left
===========
<base>
<foo att1="mostfavorite" att2="apple"/>
</base>
<base>
<foo att1="leastfavorite" att2="pear"/>
</base>and I need on right
===================
<loveit>apple</loveit>
<hateit>pear</hateit>The <loveit> node gets populated with the att2 in <foo> where att1="mostfavorite", and similarly with leastfavorite.
Seems simple enough. I tried a table looping functoid and I can gather up the values, but I can't figure out how to get them into their appropriate destination nodes.
Any help would be helpful. Details appreciated.
Thanks,
Chris
-
-
AuthorPosts
- The forum ‘BizTalk 2004 – BizTalk 2010’ is closed to new topics and replies.