Home > database >  How to replace the escape unicode characters like \u001A in a string to empty spaces
How to replace the escape unicode characters like \u001A in a string to empty spaces

Time:12-16

I have a string like A, How to convert it to B in SQL

A. "My Name is \u001AVinaykumar. I am \u001AFrom AndhraPradesh. I have completed my B.tech\u001A in Osmania University" B. "My Name is Vinaykumar. I am From AndhraPradesh. I have completed my B.tech in Osmania University"

I am trying to use the regex function but it doesn't works.

CodePudding user response:

My SQL knowledge is quite small but You can try the REPLACE() function to do this.

REPLACE(string, old_string, new_string)

Your function would look like this.

SELECT REPLACE(A, '\u001A', '');

  • Related