<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: remove special chars from a string in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/remove-special-chars-from-a-string/m-p/2132463#M448363</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;CP&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;Covers Pattern: True, if the content of operand1 fits the pattern in operand2. Wildcard characters can be used for forming the operand2 pattern, where "&lt;STRONG&gt;" represents any character string, and "+" represents any character. Upper/lower case is not taken into account. If the comparison is true, sy-fdpos contains the offset of operand2 in operand1, whereby leading wildcard characters "&lt;/STRONG&gt;" in operand2 are ignored if operand2 also contains other characters. If the comparison is false, sy-fdpos contains the length of operand1. You can select characters in operand2 for a direct comparison by adding the escape symbol "#" before the required characters. For these characters, upper/lower case is taken into account, wildcard characters and the escape symbol itself do not receive special treatment, and trailing blanks in operands of type c are not cut off.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: str1 TYPE string, &lt;/P&gt;&lt;P&gt;      str2 TYPE string. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;str1 = 'ABCDEFGH'. &lt;/P&gt;&lt;P&gt;str2 = '&lt;STRONG&gt;C&lt;/STRONG&gt;F+H'. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IF str1 CP str2. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Use &amp;lt;b&amp;gt;Translate&amp;lt;/b&amp;gt; keyword to remove the special characters by using space.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;and after that use &amp;lt;b&amp;gt;Condense&amp;lt;/b&amp;gt; .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Cheers,&lt;/P&gt;&lt;P&gt;Simha.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reward all the helpful answers..&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 02 Apr 2007 12:50:55 GMT</pubDate>
    <dc:creator>Simha_</dc:creator>
    <dc:date>2007-04-02T12:50:55Z</dc:date>
    <item>
      <title>remove special chars from a string</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/remove-special-chars-from-a-string/m-p/2132461#M448361</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi could anyone please advice me...how to remove special characters from a string...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanks in advance..&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 02 Apr 2007 12:46:03 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/remove-special-chars-from-a-string/m-p/2132461#M448361</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-04-02T12:46:03Z</dc:date>
    </item>
    <item>
      <title>Re: remove special chars from a string</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/remove-special-chars-from-a-string/m-p/2132462#M448362</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi&lt;/P&gt;&lt;P&gt;chk the sample prog:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;REPORT zstring. &lt;/P&gt;&lt;P&gt;DATA : ipstr TYPE string. &lt;/P&gt;&lt;P&gt;DATA : opstr TYPE string. &lt;/P&gt;&lt;P&gt;DATA : len TYPE i VALUE 0. &lt;/P&gt;&lt;P&gt;DATA : ch TYPE char1. &lt;/P&gt;&lt;P&gt;DATA : num TYPE i VALUE 0.   "No of Characters to be taken &lt;/P&gt;&lt;P&gt;DATA : pos TYPE char3.       "Position of Char in the Input String &lt;/P&gt;&lt;P&gt;*Input string &lt;/P&gt;&lt;P&gt;ipstr = '&amp;lt;FT&amp;gt;&amp;lt;H&amp;gt;&amp;lt;T&amp;gt; Line Clearance &amp;lt;/&amp;gt;&amp;lt;/&amp;gt;&amp;lt;/&amp;gt;'. &lt;/P&gt;&lt;P&gt;*Removing only "&amp;lt;/&amp;gt;" &lt;/P&gt;&lt;P&gt;REPLACE ALL OCCURRENCES OF '&amp;lt;/&amp;gt;' IN ipstr WITH ' '. &lt;/P&gt;&lt;P&gt;*Removing only "&amp;lt;" &lt;/P&gt;&lt;P&gt;REPLACE ALL OCCURRENCES OF '&amp;lt;' IN ipstr WITH ' '. &lt;/P&gt;&lt;P&gt;CONDENSE ipstr. &lt;/P&gt;&lt;P&gt;*Length of Input String &lt;/P&gt;&lt;P&gt;len = STRLEN( ipstr ). &lt;/P&gt;&lt;P&gt;  DO len TIMES. &lt;/P&gt;&lt;P&gt;*Char by Char &lt;/P&gt;&lt;P&gt;  ch = ipstr+pos(1). &lt;/P&gt;&lt;P&gt;  pos = pos + 1. &lt;/P&gt;&lt;P&gt;*Scan each char in input String for "&amp;gt;" &lt;/P&gt;&lt;P&gt;  FIND '&amp;gt;' IN ch IGNORING CASE. &lt;/P&gt;&lt;P&gt;  IF sy-subrc = 0. &lt;/P&gt;&lt;P&gt;    num = len - pos. &lt;/P&gt;&lt;P&gt;*Output String &lt;/P&gt;&lt;P&gt;    opstr = ipstr+pos(num). &lt;/P&gt;&lt;P&gt;  ENDIF. &lt;/P&gt;&lt;P&gt;ENDDO. &lt;/P&gt;&lt;P&gt;  WRITE &lt;span class="lia-unicode-emoji" title=":confused_face:"&gt;😕&lt;/span&gt; opstr.  &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;**reward if helpful&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;madhu&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 02 Apr 2007 12:49:00 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/remove-special-chars-from-a-string/m-p/2132462#M448362</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-04-02T12:49:00Z</dc:date>
    </item>
    <item>
      <title>Re: remove special chars from a string</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/remove-special-chars-from-a-string/m-p/2132463#M448363</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;CP&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;Covers Pattern: True, if the content of operand1 fits the pattern in operand2. Wildcard characters can be used for forming the operand2 pattern, where "&lt;STRONG&gt;" represents any character string, and "+" represents any character. Upper/lower case is not taken into account. If the comparison is true, sy-fdpos contains the offset of operand2 in operand1, whereby leading wildcard characters "&lt;/STRONG&gt;" in operand2 are ignored if operand2 also contains other characters. If the comparison is false, sy-fdpos contains the length of operand1. You can select characters in operand2 for a direct comparison by adding the escape symbol "#" before the required characters. For these characters, upper/lower case is taken into account, wildcard characters and the escape symbol itself do not receive special treatment, and trailing blanks in operands of type c are not cut off.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: str1 TYPE string, &lt;/P&gt;&lt;P&gt;      str2 TYPE string. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;str1 = 'ABCDEFGH'. &lt;/P&gt;&lt;P&gt;str2 = '&lt;STRONG&gt;C&lt;/STRONG&gt;F+H'. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IF str1 CP str2. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Use &amp;lt;b&amp;gt;Translate&amp;lt;/b&amp;gt; keyword to remove the special characters by using space.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;and after that use &amp;lt;b&amp;gt;Condense&amp;lt;/b&amp;gt; .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Cheers,&lt;/P&gt;&lt;P&gt;Simha.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reward all the helpful answers..&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 02 Apr 2007 12:50:55 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/remove-special-chars-from-a-string/m-p/2132463#M448363</guid>
      <dc:creator>Simha_</dc:creator>
      <dc:date>2007-04-02T12:50:55Z</dc:date>
    </item>
    <item>
      <title>Re: remove special chars from a string</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/remove-special-chars-from-a-string/m-p/2132464#M448364</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You can use the TRANSLATE statement or the REPLACE statement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Rich Heilman&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 02 Apr 2007 12:51:34 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/remove-special-chars-from-a-string/m-p/2132464#M448364</guid>
      <dc:creator>RichHeilman</dc:creator>
      <dc:date>2007-04-02T12:51:34Z</dc:date>
    </item>
    <item>
      <title>Re: remove special chars from a string</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/remove-special-chars-from-a-string/m-p/2132465#M448365</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hI..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data: w_text(50) type C value 'Ram?mohan?45jAGAN'.&lt;/P&gt;&lt;P&gt;data: w_len type i,&lt;/P&gt;&lt;P&gt;      W_OFF TYPE I.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;w_len = strlen( w_text ).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;do w_len times.&lt;/P&gt;&lt;P&gt; W_OFF = SY-INDEX - 1.&lt;/P&gt;&lt;P&gt; if sy-abcde cs w_text+W_OFF(1).&lt;/P&gt;&lt;P&gt; else.&lt;/P&gt;&lt;P&gt;  w_text+W_OFF(1) = SPACE.&lt;/P&gt;&lt;P&gt; ENDIF.&lt;/P&gt;&lt;P&gt;ENDDO.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CONDENSE W_TEXT.&lt;/P&gt;&lt;P&gt; WRITE : W_TEXT.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 02 Apr 2007 12:57:31 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/remove-special-chars-from-a-string/m-p/2132465#M448365</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-04-02T12:57:31Z</dc:date>
    </item>
  </channel>
</rss>

