Charlene Kerr
asked on
Remove Chinese characters in SQL
I am working with data from Hong Kong and getting alot of Chinese characters mixed in. The software I am importing into does not read these. Is there a simple way in SQL to clear out the Chinese characters from the fields?
Thanks
Thanks
ASKER
So far, a manual search and replace is sounding much simpler. Typically the data is just a name in alphanumeric followed by the name in Chinese characters, like:
Kobe Huang ¿¿¿
I'd be willing to do the work in Excel if that makes things simpler.
Thanks
Kobe Huang ¿¿¿
I'd be willing to do the work in Excel if that makes things simpler.
Thanks
ASKER
Haha... those symbols were Chinese characters until I hit submit... :)
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Thanks
The 'acceptable' characters will have character codes, just as the unacceptable characters will have character codes... so filter your data to remove the characters that are not in the acceptable 'range'. It means a lot of processing as you will be checking every character, but it should work.
Alternatively you you could some kind of regular expression/pattern matching. As to how to implement that, I found a useful article on StackOverflow Strip unwanted characters from string
I modified it slightly for your needs, so give this a go:
Open in new window