<?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 remove the string in the text ? in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/remove-the-string-in-the-text/m-p/631933#M187280</link>
    <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I would like to remove the 'CAR|ID|IL|PA|KK' in the ID column.&amp;nbsp; The result is shown in the 'Result' column.&amp;nbsp;&amp;nbsp; Please advice.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data TEST;
      infile datalines dsd;
  input ID : $300.  Result : $200.;
datalines;
	CAR ID  MA,  MA
	ILH, H
	PAUL  VN, UL VN
	KKK GGGG, K GGGG
	Card ID BMA, d BMA
	Care ID FMA, e FMA
;

run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 13 Mar 2020 15:48:12 GMT</pubDate>
    <dc:creator>ybz12003</dc:creator>
    <dc:date>2020-03-13T15:48:12Z</dc:date>
    <item>
      <title>remove the string in the text ?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/remove-the-string-in-the-text/m-p/631933#M187280</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I would like to remove the 'CAR|ID|IL|PA|KK' in the ID column.&amp;nbsp; The result is shown in the 'Result' column.&amp;nbsp;&amp;nbsp; Please advice.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data TEST;
      infile datalines dsd;
  input ID : $300.  Result : $200.;
datalines;
	CAR ID  MA,  MA
	ILH, H
	PAUL  VN, UL VN
	KKK GGGG, K GGGG
	Card ID BMA, d BMA
	Care ID FMA, e FMA
;

run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 13 Mar 2020 15:48:12 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/remove-the-string-in-the-text/m-p/631933#M187280</guid>
      <dc:creator>ybz12003</dc:creator>
      <dc:date>2020-03-13T15:48:12Z</dc:date>
    </item>
    <item>
      <title>Re: remove the string in the text ?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/remove-the-string-in-the-text/m-p/631939#M187283</link>
      <description>&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data TEST;
      infile datalines dsd;
  input ID : $300.  Result : $200.;
datalines;
	CAR ID  MA,  MA
	ILH, H
	PAUL  VN, UL VN
	KKK GGGG, K GGGG
	Card ID BMA, d BMA
	Care ID FMA, e FMA
;

run;
%let list=CAR|ID|IL|PA|KK;
data want;
 set test;
 id=strip(prxchange("s/(&amp;amp;list)//i", -1, id));
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;DIV class="branch"&gt;
&lt;DIV&gt;
&lt;DIV align="center"&gt;
&lt;TABLE class="table" summary="Procedure Print: Data Set WORK.WANT" frame="box" rules="all" cellspacing="0" cellpadding="5"&gt;
&lt;THEAD&gt;
&lt;TR&gt;
&lt;TH class="l header" scope="col"&gt;ID&lt;/TH&gt;
&lt;TH class="l header" scope="col"&gt;Result&lt;/TH&gt;
&lt;/TR&gt;
&lt;/THEAD&gt;
&lt;TBODY&gt;
&lt;TR&gt;
&lt;TD class="l data"&gt;MA&lt;/TD&gt;
&lt;TD class="l data"&gt;MA&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class="l data"&gt;H&lt;/TD&gt;
&lt;TD class="l data"&gt;H&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class="l data"&gt;UL VN&lt;/TD&gt;
&lt;TD class="l data"&gt;UL VN&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class="l data"&gt;K GGGG&lt;/TD&gt;
&lt;TD class="l data"&gt;K GGGG&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class="l data"&gt;d BMA&lt;/TD&gt;
&lt;TD class="l data"&gt;d BMA&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class="l data"&gt;e FMA&lt;/TD&gt;
&lt;TD class="l data"&gt;e FMA&lt;/TD&gt;
&lt;/TR&gt;
&lt;/TBODY&gt;
&lt;/TABLE&gt;
&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;/DIV&gt;</description>
      <pubDate>Fri, 13 Mar 2020 15:53:56 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/remove-the-string-in-the-text/m-p/631939#M187283</guid>
      <dc:creator>novinosrin</dc:creator>
      <dc:date>2020-03-13T15:53:56Z</dc:date>
    </item>
  </channel>
</rss>

