BizTalk Server Orchestration - G: SQL Message

This is Interesting: Free IT Magazines  
Home > Archive > BizTalk Server Orchestration > July 2004 > G: SQL Message





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 G: SQL Message
Guru

2004-07-22, 7:50 am


If i get the following message i can split into multiple messages(Refer 2 xml Message)

1>

<ns0:PurchaseOrders xmlns:ns0="http://BatchProcessing.PurchaseOrderBatch">
<ns1:PurchaseOrder xmlns:ns1="http://BatchProcessing.PurchaseOrder">
<PORefNumber>A1234</PORefNumber>
<PODate>2004-05-02</PODate>
<CustomerName>BPL India</CustomerName>
<POTotal>9000</POTotal>
</ns1:PurchaseOrder>
<ns1:PurchaseOrder xmlns:ns1="http://BatchProcessing.PurchaseOrder">
<PORefNumber>B4321</PORefNumber>
<PODate>2004-05-01</PODate>
<CustomerName>ACE Designers</CustomerName>
<POTotal>2000</POTotal>
</ns1:PurchaseOrder>
</ns0:PurchaseOrders>

2>

<ns0:PurchaseOrder xmlns:ns0="http://BatchProcessing.PurchaseOrder">
<PORefNumber>P1234</PORefNumber>
<PODate>1999-05-31</PODate>
<CustomerName>Shaw Wallace</CustomerName>
<POTotal>8000</POTotal>
</ns0:PurchaseOrder>


If i use a Select [ Select * from Amigos where FOR XML AUTO, ELEMENTS ]
in SQL Adapter i get the following message

<?xml version="1.0" encoding="utf-16" ?>
<AmigosRoot xmlns="http://SQLProjectReceive">

<Amigos>
<ID>1</ID>
<Name>Ashok</Name>
<Native>Raichur</Native>
<Company>Sonata</Company>
<exported>Y</exported>
</Amigos>

<Amigos>
<ID>2</ID>
<Name>Balram</Name>
<Native>Sringeri</Native>
<Company>Cap Gemini</Company>
<exported>N</exported>
</Amigos>

</AmigosRoot>


How to Spilt the Above message into

<Amigos>
<ID>1</ID>
<Name>Ashok</Name>
<Native>Raichur</Native>
<Company>Sonata</Company>
<exported>Y</exported>
</Amigos>

and

<Amigos>
<ID>2</ID>
<Name>Balram</Name>
<Native>Sringeri</Native>
<Company>Cap Gemini</Company>
<exported>N</exported>
</Amigos>


Please help me
Sponsored Links






Free braindumps | Software forum | Database administration forum

Copyright 2003 - 2008 webservertalk.com