<?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: Characters operator in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/characters-operator/m-p/12288598#M1989225</link>
    <description>&lt;P&gt;If you want to delete the GV_GLOBAL_TEXT if it contains GV_TEXT2 and not GV_TEXT1, then it is not possible as in your example, GV_TEXT2 itself contain GV_TEXT1.&lt;/P&gt;</description>
    <pubDate>Mon, 09 Nov 2020 18:20:57 GMT</pubDate>
    <dc:creator>Pankaj_Gupta</dc:creator>
    <dc:date>2020-11-09T18:20:57Z</dc:date>
    <item>
      <title>Characters operator</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/characters-operator/m-p/12288592#M1989219</link>
      <description>&lt;P&gt;Hello experts, &lt;/P&gt;
  &lt;P&gt;I want to put in IF statement a condition where I have to verify if there are 2 strings (gv_text1='PRODUCT' and gv_text2='PRODUCT2') in another string (gv_globaltext). So to delete gv_globaltext only if it contains string gv_text1 i.e. 'PRODUCT'&lt;/P&gt;
  &lt;P&gt;I want to do this dinamically and not write the 2 string explicitly like 'Product' and 'Product2' &lt;/P&gt;
  &lt;P&gt;I did the following :&lt;/P&gt;
  &lt;PRE&gt;&lt;CODE&gt;If gv_globaltext CS gv_text2.
"SKIP
ELSEIF gv_globaltext CS gv_text1.
"Delete gv_globaltext
endif.&lt;/CODE&gt;&lt;/PRE&gt;
  &lt;P&gt;But it deletes at the end both gv_text1 and gv_text2, because both contains the word 'PRODUCT' at the beginin.&lt;/P&gt;
  &lt;P&gt;Can you please help me to solve this. &lt;/P&gt;
  &lt;P&gt;Thanks in advance&lt;/P&gt;</description>
      <pubDate>Mon, 09 Nov 2020 09:34:23 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/characters-operator/m-p/12288592#M1989219</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2020-11-09T09:34:23Z</dc:date>
    </item>
    <item>
      <title>Re: Characters operator</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/characters-operator/m-p/12288593#M1989220</link>
      <description>&lt;P&gt;Hi Satish,&lt;/P&gt;&lt;P&gt;Sorry my bad, I didn't explain it very well. Actually, the strings are like: &lt;/P&gt;&lt;P&gt;'xxxProduct209112020'    Product2 + date&lt;/P&gt;&lt;P&gt;'xxxProduct09112020'      Product + date                xxxx are numbers&lt;/P&gt;&lt;P&gt;So they are not exact &lt;/P&gt;</description>
      <pubDate>Mon, 09 Nov 2020 10:30:17 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/characters-operator/m-p/12288593#M1989220</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2020-11-09T10:30:17Z</dc:date>
    </item>
    <item>
      <title>Re: Characters operator</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/characters-operator/m-p/12288594#M1989221</link>
      <description>&lt;P&gt;Hello &lt;SPAN class="mention-scrubbed"&gt;essaouira&lt;/SPAN&gt;,&lt;/P&gt;&lt;P&gt;I just checked with below test code, it works fine for me. Can you check and correct me if my understanding is wrong.&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;DATA: gv1 TYPE string VALUE 'PRODUCT',
      gv2 TYPE string VALUE 'PRODUCT2',
      gv3 TYPE string VALUE 'aDKHSkjxnkjproductkjdakj'.

IF  gv3 CS gv2.
  WRITE: 1.
ELSEIF gv3 CS gv1.
  WRITE: 2.
ENDIF.&lt;BR /&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;Regards!&lt;/P&gt;</description>
      <pubDate>Mon, 09 Nov 2020 10:39:14 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/characters-operator/m-p/12288594#M1989221</guid>
      <dc:creator>former_member1716</dc:creator>
      <dc:date>2020-11-09T10:39:14Z</dc:date>
    </item>
    <item>
      <title>Re: Characters operator</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/characters-operator/m-p/12288595#M1989222</link>
      <description>&lt;PRE&gt;&lt;CODE&gt;If gv_globaltext CS gv_text1 and gv_global_text NS gv_text2.
  "Delete gv_globaltext
ENDIF.&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 09 Nov 2020 10:39:56 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/characters-operator/m-p/12288595#M1989222</guid>
      <dc:creator>matt</dc:creator>
      <dc:date>2020-11-09T10:39:56Z</dc:date>
    </item>
    <item>
      <title>Re: Characters operator</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/characters-operator/m-p/12288596#M1989223</link>
      <description>&lt;P&gt;Thank you &lt;SPAN class="mention-scrubbed"&gt;matthew.billingham&lt;/SPAN&gt; it works. and just one more question please. Suppose if we want the inverse (delete gs_text2 only) how can we do it please? (because with the same code it's not working)&lt;/P&gt;</description>
      <pubDate>Mon, 09 Nov 2020 12:11:38 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/characters-operator/m-p/12288596#M1989223</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2020-11-09T12:11:38Z</dc:date>
    </item>
    <item>
      <title>Re: Characters operator</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/characters-operator/m-p/12288597#M1989224</link>
      <description>&lt;P&gt;You really need to read the documentation of what CS and NS mean. It is trivially obvious why, with gv_text2 = 'PRODUCT2' and gv_text1 = 'PRODUCT',&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;If gv_globaltext CS gv_text2 and gv_global_text NS gv_text1.
  "Delete gv_globaltext
ENDIF.&amp;lt;br&amp;gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;doesn't work.&lt;/P&gt;&lt;P&gt;Maybe a quick look at how boolean operations like AND work would be of value also. I'm not going to assist further: I was happy to help with some syntax, but as far as I'm concerned this site doesn't exist to teach basic programming. Programming by guessing is never going to work - you have to understand what you are doing and why.&lt;/P&gt;</description>
      <pubDate>Mon, 09 Nov 2020 18:18:49 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/characters-operator/m-p/12288597#M1989224</guid>
      <dc:creator>matt</dc:creator>
      <dc:date>2020-11-09T18:18:49Z</dc:date>
    </item>
    <item>
      <title>Re: Characters operator</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/characters-operator/m-p/12288598#M1989225</link>
      <description>&lt;P&gt;If you want to delete the GV_GLOBAL_TEXT if it contains GV_TEXT2 and not GV_TEXT1, then it is not possible as in your example, GV_TEXT2 itself contain GV_TEXT1.&lt;/P&gt;</description>
      <pubDate>Mon, 09 Nov 2020 18:20:57 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/characters-operator/m-p/12288598#M1989225</guid>
      <dc:creator>Pankaj_Gupta</dc:creator>
      <dc:date>2020-11-09T18:20:57Z</dc:date>
    </item>
  </channel>
</rss>

