Message Assignment
Web Server forum
Back To The Forum Home!Search!Private Messaging System

Web Server Talk Web Server Talk > Web Servers reviews > BizTalk Server > BizTalk Server Orchestration > Message Assignment




  Last Thread   Next Thread Next
  Show Printable Version Email this Page Subscribe to this Thread      Post New Thread    Post A Reply      

    Message Assignment  
Sandeep


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
09-16-05 10:58 PM

Hi,

I have an orchestration in which i am constructing a message. This is done
inside a Message Construct Shape. Within that, i have a transform shape,
which calls a map (which maps my source and destination schemas).
Once the transform is complete, i have a Message Assignment shape. Within
this Message Assignment, i update certain elements of the transformed messag
e
using XPATH. e.g
xpath(MsgIn, "/*[local-name()='Order' and
namespace-uri()='httpTrx-1']/*[local-name()='OrderType' and
namespace-uri()='']/*[local-name()='Order_Items' and
namespace-uri()='']/*[local-name()='OrderLine' and
namespace-uri()='']/*[local-name()='ITEM' and namespace-uri()='']") =
sItemnumber;

Here i am updating the ITEM element in the OrderLine node to a value stored
in a variable sItemnumber.
This works fine so long as the source XML file has a single header and
detail line.
If i have a source XML instance with multiple lines, i get the error -
The XPath expression 'expr......' selected a node which is not valid for
property or distinguished field retrieval, or it selected no node at all.
Only text-only elements or attributes may be selected.

Exception type: XPathSelectionException
Source: Microsoft.XLANGs.Engine
Target Site: Void XPathStore(System.Object, System.String)

I would have liked to assign values to each of the detail node elements
using XPATH.
Is that something possible?

Thanks in advance.

Sandeep.







[ Post a follow-up to this message ]



    Re: Message Assignment  
Matt Milner


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
09-18-05 07:48 AM

You can use the position() function in your xpath predicates to get each
item, but you'll probably want to do this in a loop shape so that you have
some index to use each time you set the values.

Matt


"Sandeep" <Sandeep@discussions.microsoft.com> wrote in message
news:A8D77486-4D7D-4115-8BCF-1B294A53F5B7@microsoft.com...
> Hi,
>
> I have an orchestration in which i am constructing a message. This is done
> inside a Message Construct Shape. Within that, i have a transform shape,
> which calls a map (which maps my source and destination schemas).
> Once the transform is complete, i have a Message Assignment shape. Within
> this Message Assignment, i update certain elements of the transformed
> message
> using XPATH. e.g
> xpath(MsgIn, "/*[local-name()='Order' and
> namespace-uri()='httpTrx-1']/*[local-name()='OrderType' and
> namespace-uri()='']/*[local-name()='Order_Items' and
> namespace-uri()='']/*[local-name()='OrderLine' and
> namespace-uri()='']/*[local-name()='ITEM' and namespace-uri()='']") =
> sItemnumber;
>
> Here i am updating the ITEM element in the OrderLine node to a value
> stored
> in a variable sItemnumber.
> This works fine so long as the source XML file has a single header and
> detail line.
> If i have a source XML instance with multiple lines, i get the error -
> The XPath expression 'expr......' selected a node which is not valid for
> property or distinguished field retrieval, or it selected no node at all.
> Only text-only elements or attributes may be selected.
>
> Exception type: XPathSelectionException
> Source: Microsoft.XLANGs.Engine
> Target Site: Void XPathStore(System.Object, System.String)
>
> I would have liked to assign values to each of the detail node elements
> using XPATH.
> Is that something possible?
>
> Thanks in advance.
>
> Sandeep.
>
>







[ Post a follow-up to this message ]



    Sponsored Links  




 





   All times are GMT. The time now is 06:36 PM.      Post New Thread    Post A Reply      
  Last Thread   Next Thread Next


Most Popular forums 

Forum Jump:
Rate This Thread:

Forum Rules:
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is OFF
vB code is ON
Smilies are ON
[IMG] code is OFF
 
Medical and Health forum | Computer Games Reviews | Graphics design forum

Back To The Top
Home | Usercp | Faq | Register