|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
Remove special characters form string |
« View previous topic :: View next topic » |
Author |
Message
|
Ashok Kumar |
Posted: Mon Nov 02, 2015 11:34 pm Post subject: Remove special characters form string |
|
|
Acolyte
Joined: 01 Jul 2013 Posts: 53
|
Hi All,
Could you please tell me how can we remove UTF-16 BE ENCODING special characters from string using ESQL.
Thanks in advance. |
|
Back to top |
|
 |
timber |
Posted: Tue Nov 03, 2015 1:30 am Post subject: |
|
|
 Grand Master
Joined: 25 Aug 2015 Posts: 1292
|
Two important questions:
- why do you need to remove the special characters?
- When removing these characters, why is the encoding ( UTF16-BE ) important? |
|
Back to top |
|
 |
Vitor |
Posted: Tue Nov 03, 2015 5:36 am Post subject: Re: Remove special characters form string |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
Ashok Kumar wrote: |
Could you please tell me how can we remove UTF-16 BE ENCODING special characters from string using ESQL. |
So do you:
a) want to remove the encoding information so that no-one can ever read the string again
b) want to remove the encoding information because whatever's reading the string doesn't use UTF-16 BE?
If it's the former, just blank out the string. If it's the latter (as I suspect), you're much better off changing the code page of the string to whatever the consuming application needs because that's probably going to work and just stripping off the encoding isn't. _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
timber |
Posted: Tue Nov 03, 2015 7:52 am Post subject: |
|
|
 Grand Master
Joined: 25 Aug 2015 Posts: 1292
|
It didn't occur to me that the OP might be asking about the Byte Order Mark at the beginning of the string. I thought the question was about 'special characters' in general...which just confirms my dislike of the term 'special characters'.
@Ashok Kumar: Please clarify. Do you want to
a) remove the two bytes of the UTF-16 BOM from the beginning of a string
or
b) remove non-ASCII characters from a string?
Either way, please also explain why you need to do this - our advice may change depending on your requirements. |
|
Back to top |
|
 |
|
|
 |
|
Page 1 of 1 |
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|
|
|