Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7718169
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T03:05:59+00:00 2026-06-01T03:05:59+00:00

Hi I am trying to insert a XML file in to SQL Server table

  • 0

Hi I am trying to insert a XML file in to SQL Server table filed of type XML

but this is giving me error as below

This is my C# logic

  using (Entities context = new Entities())
            {
                context.usp_BF_StoreEligibilityResponse(ID, XML);
}

this is my Stored Procedure

 UPDATE  MyTable
SET     ResponseXML = cast('<?xml version="1.0"?>
<Interchange segment-terminator="~" element-separator="*" sub-element-separator="&gt;">
  <ISA>
    <!--Author Information Qualifier-->
    <ISA01>00<!--No Authorization Information Present--></ISA01>
    <!--Author Information-->
    <ISA02>          </ISA02>
    <!--Security Information Qualifer-->
    <ISA03>01<!--Password--></ISA03>
    <!--Security Information-->
    <ISA04>JILITTQQPK</ISA04>
    <!--Interchange ID Qualifier-->
    <ISA05>ZZ<!--Mutually Defined--></ISA05>
    <!--Interchange Sender ID-->
    <ISA06>S00000000000001</ISA06>
    <!--Interchange ID Qualifier-->
    <ISA07>ZZ<!--Mutually Defined--></ISA07>
    <!--Interchange Receiver ID-->
    <ISA08>T00000000021261</ISA08>
    <!--Interchange Date-->
    <ISA09>120328</ISA09>
    <!--Interchange Time-->
    <ISA10>1539</ISA10>
    <!--Inter Control Standards Identifier-->
    <ISA11>&#x1F;</ISA11>
    <!--Inter Control Version Number-->
    <ISA12>00501</ISA12>
    <!--Inter Control Number-->
    <ISA13>021443719</ISA13>
    <!--Acknowlegment Requested-->
    <ISA14>0<!--No Acknowledgment Requested--></ISA14>
    <!--Usage Indicator-->
    <ISA15>T<!--Test Data--></ISA15>
    <!--Component Element Separator-->
    <ISA16>
      <ISA1601 />
      <ISA1602 />
    </ISA16>
  </ISA>
  <TA1>
    <!--Interchange control number-->
    <TA101>0fa080e2-</TA101>
    <!--Interchange Date-->
    <TA102>120328</TA102>
    <!--Interchange Time-->
    <TA103>1639</TA103>
    <!--Interchange ACK Code-->
    <TA104>R<!--Interchange rejected/suspended--></TA104>
    <!--Interchange Note Code-->
    <TA105>018</TA105>
  </TA1>
  <IEA>
    <!--Number of Included Functional Groups-->
    <IEA01>0</IEA01>
    <!--Interchange Control Number-->
    <IEA02>021443719</IEA02>
  </IEA>
</Interchange>' AS XML)
WHERE   EligibilityID = 13

Error Message

Msg 9420, Level 16, State 1, Line 1
XML parsing: line 25, character 17, illegal xml character
    enter code here

This is the line causing this error
<ISA11>&#x1F;</ISA11>

this when i preview in Visual Studio XML view or HTML view
it looks like this <ISA11></ISA11>

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-01T03:06:00+00:00Added an answer on June 1, 2026 at 3:06 am

    The error message says it’s all. Given XML is invalid XML since &#x1F; is invalid text sequence. If you want such text it must be entered as &amp;#x1F; (&amp; is an XML escape sequence for & symbol). Alternatively, you can escape string by enclosing it with a CDATA (character data) section: <![CDATA[&#x1F;]]>.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Hello I'm trying to insert some XML data into a table on SQL Server
I was trying to insert new data into an existing XML file, but it's
Am trying to insert XML into XML Column.. getting following error: . Msg 6819,
While trying to insert data to my SQl db i get the following error
I'm trying to insert some import lines into a python source file, but i
I am trying to insert a time only value, but get the following error
I am trying to insert xml elements into an xml file using XSLT. I
I'm trying to insert some HTML at a given point. The XML file has
I'm trying parse an xml file and insert it into an mysql database. The
I am trying to insert data of Books by parsing XML file. It allows

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.