How to remove the special character that forms inside a String in SQL?

Asked

Viewed 89 times

0

I am using the excerpt below in my code, but when inserting > inside a String, it returns the result as &gt ;, the same is converting to HTML entity, as I can use '>', without problems?

'"name":"'+RTRIM(CONVERT(VARCHAR(100),CAT.DESCRICAO))+ '>' + CATP.DESCRICAO + '"}',','

Select result:

[{"code":"182574","name":"SMARTPHONE &gt ; TELEPHONY"}]

  • Have you tried the U02C3 exhaust sequence?

  • Unfortunately it is impossible to reproduce the problem only with the code snippet that you reported. Provide a minimum executable example so we can help you with your question

  • You can inform your SELECT complete?

  • It is worth remembering that the SQL-Server does not allow concatenating values that are not of the same data_type, in case you don’t know, I’d advise taking a look at this contents related.

1 answer

1


I solved the problem using ' ', I found this character in the Windows character map, it solved my problem.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.