Flat file schema issues

Home Page › Forums › BizTalk 2004 – BizTalk 2010 › Flat file schema issues

Viewing 0 reply threads
  • Author
    Posts
    • #18603

      I am trying to generate a schema from a flat file with the below structure:

      [DOCSTART]
      [COPY]N
      [ACCOUNT.NUMBER]12345678
      [TOTAL.DUE]1
      [ACCOUNT.NUMBER]12345677
      [TOTAL.DUE]2
      [ACCOUNT.NUMBER]12345671
      [TOTAL.DUE]3
      [EOT]EOT
      [DOCEND]

      The ACCOUNT.NUMBER and TOTAL.DUE fields can repeat as shown above. Each line is terminated by a carriage return linefeed with the exception of the [DOCEND] line.

      when this schema is tested I am getting the error:

      Unexpected data found while looking for: “\r\n” 

      Any help on this would be great.

      The Schema I have generated is shown below:

        <?xml version=”1.0″ encoding=”utf-16″ ?>
      – <xs:annotation>
      – <xs:appinfo>
        <schemaEditorExtension:schemaInfo namespaceAlias=”b“ extensionClass=”Microsoft.BizTalk.FlatFileExtension.FlatFileExtension“ standardName=”Flat File“ xmlns:schemaEditorExtension=”http://schemas.microsoft.com/BizTalk/2003/SchemaEditorExtensions“ />
        <b:schemaInfo standard=”Flat File“ codepage=”65001“ default_pad_char=”“ pad_char_type=”char“ count_positions_by_byte=”false“ parser_optimization=”complexity“ lookahead_depth=”0“ suppress_empty_nodes=”false“ generate_empty_nodes=”true“ allow_early_termination=”false“ early_terminate_optional_fields=”false“ allow_message_breakup_of_infix_root=”false“ compile_parse_tables=”false“ root_reference=”Root“ />
        </xs:appinfo>
        </xs:annotation>
      – <xs:element name=”Root“>
      – <xs:annotation>
      – <xs:appinfo>
        <b:recordInfo structure=”delimited“ child_delimiter_type=”hex“ child_delimiter=”0xD 0xA“ child_order=”infix“ sequence_number=”1“ preserve_delimiter_for_empty_data=”true“ suppress_trailing_delimiters=”false“ />
        </xs:appinfo>
        </xs:annotation>
      – <xs:complexType>
      – <xs:sequence>
      – <xs:annotation>
      – <xs:appinfo>
        <groupInfo sequence_number=”0“ xmlns=”http://schemas.microsoft.com/BizTalk/2003“ />
        </xs:appinfo>
        </xs:annotation>
      – <xs:element name=”DOCSTART“>
      – <xs:annotation>
      – <xs:appinfo>
        <b:recordInfo structure=”delimited“ child_delimiter_type=”hex“ child_delimiter=”0xD 0xA“ child_order=”postfix“ sequence_number=”1“ preserve_delimiter_for_empty_data=”true“ suppress_trailing_delimiters=”false“ />
        </xs:appinfo>
        </xs:annotation>
      – <xs:complexType>
      – <xs:sequence>
      – <xs:annotation>
      – <xs:appinfo>
        <groupInfo sequence_number=”0“ xmlns=”http://schemas.microsoft.com/BizTalk/2003“ />
        </xs:appinfo>
        </xs:annotation>
      – <xs:element name=”DOCSTART_Child1“ type=”xs:string“>
      – <xs:annotation>
      – <xs:appinfo>
        <b:fieldInfo justification=”left“ sequence_number=”1“ />
        </xs:appinfo>
        </xs:annotation>
        </xs:element>
        </xs:sequence>
        </xs:complexType>
        </xs:element>
      – <xs:element name=”COPY“>
      – <xs:annotation>
      – <xs:appinfo>
        <b:recordInfo structure=”positional“ sequence_number=”2“ preserve_delimiter_for_empty_data=”true“ suppress_trailing_delimiters=”false“ />
        </xs:appinfo>
        </xs:annotation>
      – <xs:complexType>
      – <xs:sequence>
      – <xs:annotation>
      – <xs:appinfo>
        <groupInfo sequence_number=”0“ xmlns=”http://schemas.microsoft.com/BizTalk/2003“ />
        </xs:appinfo>
        </xs:annotation>
      – <xs:element name=”COPY_Child1“ type=”xs:string“>
      – <xs:annotation>
      – <xs:appinfo>
        <b:fieldInfo justification=”left“ pos_offset=”0“ pos_length=”6“ sequence_number=”1“ />
        </xs:appinfo>
        </xs:annotation>
        </xs:element>
      – <xs:element name=”COPY_Child2“ type=”xs:string“>
      – <xs:annotation>
      – <xs:appinfo>
        <b:fieldInfo justification=”left“ pos_offset=”0“ pos_length=”1“ sequence_number=”2“ />
        </xs:appinfo>
        </xs:annotation>
        </xs:element>
        </xs:sequence>
        </xs:complexType>
        </xs:element>
      – <xs:element maxOccurs=”1“ name=”DETAILS“>
      – <xs:annotation>
      – <xs:appinfo>
        <b:recordInfo structure=”delimited“ preserve_delimiter_for_empty_data=”true“ suppress_trailing_delimiters=”false“ sequence_number=”3“ child_delimiter_type=”hex“ child_delimiter=”0x0D0A“ child_order=”infix“ />
        </xs:appinfo>
        </xs:annotation>
      – <xs:complexType>
      – <xs:choice>
      – <xs:annotation>
      – <xs:appinfo>
        <groupInfo sequence_number=”0“ xmlns=”http://schemas.microsoft.com/BizTalk/2003“ />
        </xs:appinfo>
        </xs:annotation>
      – <xs:element minOccurs=”1“ maxOccurs=”unbounded“ name=”ACCOUNTDETAILS“>
      – <xs:annotation>
      – <xs:appinfo>
        <b:recordInfo structure=”positional“ sequence_number=”1“ preserve_delimiter_for_empty_data=”true“ suppress_trailing_delimiters=”false“ />
        </xs:appinfo>
        </xs:annotation>
      – <xs:complexType>
      – <xs:sequence>
      – <xs:annotation>
      – <xs:appinfo>
        <groupInfo sequence_number=”0“ xmlns=”http://schemas.microsoft.com/BizTalk/2003“ />
        </xs:appinfo>
        </xs:annotation>
      – <xs:element minOccurs=”1“ maxOccurs=”1“ name=”ACCOUNTDETAILS_Child1“ type=”xs:string“>
      – <xs:annotation>
      – <xs:appinfo>
        <b:fieldInfo justification=”left“ pos_offset=”0“ pos_length=”16“ sequence_number=”1“ />
        </xs:appinfo>
        </xs:annotation>
        </xs:element>
      – <xs:element minOccurs=”1“ maxOccurs=”1“ name=”ACCOUNTDETAILS_Child2“ type=”xs:string“>
      – <xs:annotation>
      – <xs:appinfo>
        <b:fieldInfo justification=”left“ pos_offset=”0“ pos_length=”8“ sequence_number=”2“ />
        </xs:appinfo>
        </xs:annotation>
        </xs:element>
        </xs:sequence>
        </xs:complexType>
        </xs:element>
      – <xs:element minOccurs=”1“ maxOccurs=”unbounded“ name=”TOTAL“>
      – <xs:annotation>
      – <xs:appinfo>
        <b:recordInfo structure=”positional“ sequence_number=”2“ preserve_delimiter_for_empty_data=”true“ suppress_trailing_delimiters=”false“ />
        </xs:appinfo>
        </xs:annotation>
      – <xs:complexType>
      – <xs:sequence>
      – <xs:annotation>
      – <xs:appinfo>
        <groupInfo sequence_number=”0“ xmlns=”http://schemas.microsoft.com/BizTalk/2003“ />
        </xs:appinfo>
        </xs:annotation>
      – <xs:element minOccurs=”1“ maxOccurs=”1“ name=”TOTAL_Child1“ type=”xs:string“>
      – <xs:annotation>
      – <xs:appinfo>
        <b:fieldInfo justification=”left“ pos_offset=”0“ pos_length=”11“ sequence_number=”1“ />
        </xs:appinfo>
        </xs:annotation>
        </xs:element>
      – <xs:element minOccurs=”1“ maxOccurs=”1“ name=”TOTAL_Child2“ type=”xs:string“>
      – <xs:annotation>
      – <xs:appinfo>
        <b:fieldInfo justification=”left“ pos_offset=”0“ pos_length=”1“ sequence_number=”2“ />
        </xs:appinfo>
        </xs:annotation>
        </xs:element>
        </xs:sequence>
        </xs:complexType>
        </xs:element>
        </xs:choice>
        </xs:complexType>
        </xs:element>
      – <xs:element name=”EOT“>
      – <xs:annotation>
      – <xs:appinfo>
        <b:recordInfo structure=”positional“ sequence_number=”4“ preserve_delimiter_for_empty_data=”true“ suppress_trailing_delimiters=”false“ />
        </xs:appinfo>
        </xs:annotation>
      – <xs:complexType>
      – <xs:sequence>
      – <xs:annotation>
      – <xs:appinfo>
        <groupInfo sequence_number=”0“ xmlns=”http://schemas.microsoft.com/BizTalk/2003“ />
        </xs:appinfo>
        </xs:annotation>
      – <xs:element name=”EOT_Child1“ type=”xs:string“>
      – <xs:annotation>
      – <xs:appinfo>
        <b:fieldInfo justification=”left“ pos_offset=”0“ pos_length=”5“ sequence_number=”1“ />
        </xs:appinfo>
        </xs:annotation>
        </xs:element>
      – <xs:element name=”EOT_Child2“ type=”xs:string“>
      – <xs:annotation>
      – <xs:appinfo>
        <b:fieldInfo justification=”left“ pos_offset=”0“ pos_length=”3“ sequence_number=”2“ />
        </xs:appinfo>
        </xs:annotation>
        </xs:element>
        </xs:sequence>
        </xs:complexType>
        </xs:element>
      – <xs:element name=”DOCEND“>
      – <xs:annotation>
      – <xs:appinfo>
        <b:recordInfo structure=”positional“ sequence_number=”5“ preserve_delimiter_for_empty_data=”true“ suppress_trailing_delimiters=”false“ />
        </xs:appinfo>
        </xs:annotation>
      – <xs:complexType>
      – <xs:sequence>
      – <xs:annotation>
      – <xs:appinfo>
        <groupInfo sequence_number=”0“ xmlns=”http://schemas.microsoft.com/BizTalk/2003“ />
        </xs:appinfo>
        </xs:annotation>
      – <xs:element name=”DOCEND_Child1“ type=”xs:string“>
      – <xs:annotation>
      – <xs:appinfo>
        <b:fieldInfo justification=”left“ pos_offset=”0“ pos_length=”1“ sequence_number=”1“ />
        </xs:appinfo>
        </xs:annotation>
        </xs:element>
        </xs:sequence>
        </xs:complexType>
        </xs:element>
        </xs:sequence>
        </xs:complexType>
        </xs:element>
        </xs:schema>

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