SQL Adapter Schema mapping

Home Page Forums BizTalk 2004 – BizTalk 2010 SQL Adapter Schema mapping

Viewing 1 reply thread
  • Author
    Posts
    • #20190

      Hi,

       

         I am using SQl adapter to pull records from a sql server table with simple select statement. Adapter generates its own schema. Now, I want to map this autogenerated schema to anothe schema for some processing. I am not able to do that. I just tried. orch. does not shows any error and their are no results. 

      I am pasting SQl adapter generated schema for ref.

      Sql schema XSD is

       

      <?xml version=”1.0″ encoding=”utf-16″?>
      <xsTongue Tiedchema xmlns:b=”http://schemas.microsoft.com/BizTalk/2003” attributeFormDefault=”unqualified” elementFormDefault=”qualified” targetNamespace=”http://Time_Sheet” version=”1.0″ xmlns:xs=”http://www.w3.org/2001/XMLSchema“>
        <xs:annotation>
          <xs:appinfo>
            <msbtssqlTongue TiedqlScript value=”SELECT Client_Name,Convert(nvarchar,TS_Date,101)as date,Hours,TS_Descr,TS_User FROM dbo.Time_Sheet as TS Inner Join dbo.TS_Client as TSC ON TS.Client_Id = TSC.Client_ID AND trnsfr=0 for XML AUTO, ELEMENTS” xmlns:msbtssql=”http://schemas.microsoft.com/BizTalk/2003” />
            <schemaInfo is_envelope=”yes” xmlns=”http://schemas.microsoft.com/BizTalk/2003” />
          </xs:appinfo>
        </xs:annotation>
        <xs:element name=”TS”>
          <xs:annotation>
            <xs:appinfo>
              <recordInfo body_xpath=”/*[local-name()=’TS’ and namespace-uri()=’http://Time_Sheet’%5D/*%5Blocal-name()=’TSC&#8217; and namespace-uri()=’http://Time_Sheet’%5D&#8221; xmlns=”http://schemas.microsoft.com/BizTalk/2003” />
            </xs:appinfo>
          </xs:annotation>
          <xs:complexType>
            <xsTongue Tiedequence>
              <xs:element xmlns:q1=”http://Time_Sheet” minOccurs=”0″ maxOccurs=”1″ name=”TSC” type=”q1:TSCType” />
            </xsTongue Tiedequence>
          </xs:complexType>
        </xs:element>
        <xs:complexType name=”TSCType”>
          <xs:choice minOccurs=”0″ maxOccurs=”unbounded”>
            <xs:element xmlns:q2=”http://Time_Sheet” maxOccurs=”unbounded” name=”TS” type=”q2:TSType” />
            <xs:element xmlns:q3=”http://Time_Sheet” name=”Client_Name” type=”q3:Client_NameType” />
            <xs:element xmlns:q4=”http://Time_Sheet” name=”date” type=”q4Big SmileateType” />
          </xs:choice>
        </xs:complexType>
        <xs:complexType name=”Client_NameType”>
          <xsTongue TiedimpleContent>
            <xs:extension base=”xsTongue Tiedtring” />
          </xsTongue TiedimpleContent>
        </xs:complexType>
        <xs:complexType name=”dateType”>
          <xsTongue TiedimpleContent>
            <xs:extension base=”xsTongue Tiedtring” />
          </xsTongue TiedimpleContent>
        </xs:complexType>
        <xs:complexType name=”TSType”>
          <xs:choice minOccurs=”0″ maxOccurs=”unbounded”>
            <xs:element xmlns:q5=”http://Time_Sheet” name=”Hours” type=”q5:HoursType” />
            <xs:element xmlns:q6=”http://Time_Sheet” name=”TS_Descr” type=”q6:TS_DescrType” />
            <xs:element xmlns:q7=”http://Time_Sheet” name=”TS_User” type=”q7:TS_UserType” />
          </xs:choice>
        </xs:complexType>
        <xs:complexType name=”HoursType”>
          <xsTongue TiedimpleContent>
            <xs:extension base=”xsTongue Tiedhort” />
          </xsTongue TiedimpleContent>
        </xs:complexType>
        <xs:complexType name=”TS_DescrType”>
          <xsTongue TiedimpleContent>
            <xs:extension base=”xsTongue Tiedtring” />
          </xsTongue TiedimpleContent>
        </xs:complexType>
        <xs:complexType name=”TS_UserType”>
          <xsTongue TiedimpleContent>
            <xs:extension base=”xsTongue Tiedtring” />
          </xsTongue TiedimpleContent>
        </xs:complexType>
      </xsTongue Tiedchema>

       

      I am really trying hard for mapping this schema to another.

      Any suggestions is more then welcome.

      Thank you in advance.

       

       

    • #20221

      Anon,

      When the adapter wizard generates your sql adapter schema (that you posted above), the schema will be ‘saved’ to your project. You will need to create a new map and select this sql adapter schema as your source message and select another schema as the destination message – hook up the two schemas as per a normal map.

      HTH, Nick.

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