Mapping

Viewing 1 reply thread
  • Author
    Posts
    • #20732

       Hi
      I am trying to create a biztalk map that will take the following XML:
        <correspondence>
          <head>
            <to>Andile</to>
            <country>SA</country>
          </head>
          <addresses>
            <address>Box 234</address>
            <address>34 Mowbury</address>
          </addresses>
        </correspondence>

      and output the following:

      <Addresses>
        <address>
          <to>Andile</to>
          <country>SA</country>
          <addr>Box 234</addr>
        </address>
        <address>
          <to>Andile</to>
          <country>SA</country>
          <addr>34 Mowbury</addr>
        </address>
      </Addresses>

      Please help with this as It does not seem to be working

    • #20737

       You can do this in ways.

      1. Use Inline XSLT

      2. or use Table loop funtoid. Functoid first param will be addresses node and connect that to “Addresses” node at destination.  “address” will be the 2nd param, “to” theird param and “country” forth param.  use 3 Extract funtoid to ge the values from table loop and point to destination.

      I hope 2nd will be the easy way.

      Let me know how it goes.

      siva

      • #20744

        I think it seems to be a straight forward mapping. Try the below and see if it works.

        Create the source and destination schemas with value of max occurs for “address” element under “addresses” to unbounded. Map the elements “to”, “country” and “address” in source schema to “to”, “country” and “addr” in destination schema. (Assuming that value of maxOccurs for “to” and “country” in source schema is 1).

      • #20749

         I used the customized XSL. Seems to be working like magic

        Thank you

         

        Wonder Andile Hlongwane

Viewing 1 reply thread
  • The forum ‘BizTalk 2004 – BizTalk 2010’ is closed to new topics and replies.