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 8750341
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T12:50:58+00:00 2026-06-13T12:50:58+00:00

When trying to convert records to xml in sql, I get the following error

  • 0

When trying to convert records to xml in sql, I get the following error message:

Msg 6841, Level 16, State 1, Procedure trg_missacct_upd_del, Line 58
FOR XML could not serialize the data for node ‘AltAddr’ because it contains a character (0x0002)which is not allowed in XML. To retrieve
this data using FOR XML, convert it to binary, varbinary or image data
type and use the BINARY BASE64 directive.

I want to write a query to find which record has this hex value (0x0002). I’ve tried something like this:

select * from missacct where altaddr like '%' + 0x0002 + '%'

Is there a way to query out this record?

  • 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-13T12:50:58+00:00Added an answer on June 13, 2026 at 12:50 pm
    SELECT * FROM missacct WHERE altaddr LIKE '%' + CHAR(0x0002) + '%'
    

    or you could do

    SELECT * FROM missacct WHERE CHARINDEX( CHAR(0x0002), altaddr ) >0
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have the following stored procedure that I am trying to convert to a
Trying to convert output from a rest_client GET to the characters that are represented
Trying to convert the following but am having difficulty. Can anyone see where I'm
I have the SQL and trying to convert ti to Linq query. I need
I want to get records from sql server 2005 in datetime format like this
I am trying to use powershell to convert a csv to an xml table.
I am trying to convert a query to return as xml in the correct
I'm trying to convert this SQL into a Linq2SQL query, however, I'm at the
Hey I am trying to find a way to get my post records filtered.
In sp here I am trying to get a count of how many records

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.