none
BizTalk - Assign complete xml to 1 field of type System.String RRS feed

  • Question

  • I have below xml as input dropped in my Receive location, this complete xml should be sent to one particular field in destination schema which is of type System.String (schema produced from web service) shown below. I am using Orchestration to convert this XmlDoc.OuterXml (input message) assigned to variable System.String.

    <ns0:Record xmlns:ns0="http://Munchein.Grouping">
    	<Body>
    		<VendorID>21000002289</VendorID>
    		<InvoiceID>20150603E</InvoiceID>
    		<InvoiceDate>06/03/2015</InvoiceDate>
    		<InvoiceDueDate>06/03/2015</InvoiceDueDate>
    		<CompanyID>1011</CompanyID>
    		<Detail>
    			<CompanyID>1011</CompanyID>
    			<Dimension>US00-DLSMD-102000-000-10-AC3</Dimension>
    			<Account>4000010</Account>
    		</Detail>
    		<Detail>
    			<CompanyID>1011</CompanyID>
    			<Dimension>US00-DLSMD-102000-000-10-AC3</Dimension>
    			<Account>4000024</Account>
    		</Detail>
    		
    	</Body>
    </ns0:Record>

    Web service schema is below :

    <?xml version="1.0" encoding="utf-16"?>
    <xs:schema xmlns:b="http://schemas.microsoft.com/BizTalk/2003" xmlns:tns="http://tempuri.org/" elementFormDefault="qualified" targetNamespace="http://tempuri.org/" xmlns:xs="http://www.w3.org/2001/XMLSchema">
      <xs:element name="BindDbx">
        <xs:complexType>
          <xs:sequence>
            <xs:element minOccurs="0" maxOccurs="1" name="sXml" type="xs:string" />
          </xs:sequence>
        </xs:complexType>
      </xs:element>
      <xs:element name="BindDbxResponse">
        <xs:complexType>
          <xs:sequence>
            <xs:element minOccurs="0" maxOccurs="1" name="BindDbxResult">
              <xs:complexType mixed="true">
                <xs:sequence>
                  <xs:any />
                </xs:sequence>
              </xs:complexType>
            </xs:element>
          </xs:sequence>
        </xs:complexType>
      </xs:element>
      <xs:element name="Put">
        <xs:annotation>
          <xs:appinfo>
            <properties xmlns="http://schemas.microsoft.com/BizTalk/2003">
              <property distinguished="true" xpath="/*[local-name()='Put' and namespace-uri()='http://tempuri.org/']/*[local-name()='sXml' and namespace-uri()='http://tempuri.org/']" />
            </properties>
          </xs:appinfo>
        </xs:annotation>
        <xs:complexType>
          <xs:sequence>
            <xs:element minOccurs="0" maxOccurs="1" name="sXml" type="xs:string" />
          </xs:sequence>
        </xs:complexType>
      </xs:element>
      <xs:element name="PutResponse">
        <xs:complexType>
          <xs:sequence>
            <xs:element minOccurs="0" maxOccurs="1" name="PutResult">
              <xs:complexType mixed="true">
                <xs:sequence>
                  <xs:any />
                </xs:sequence>
              </xs:complexType>
            </xs:element>
          </xs:sequence>
        </xs:complexType>
      </xs:element>
    </xs:schema>

    As you can see the element 'Put' is of dataType  'System.String' .

    How can I assign my complete xml to this one field ?


    MBH

    Wednesday, June 10, 2015 10:47 PM

Answers

All replies