<?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: prxmatch not working with variable names as parameter in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/prxmatch-not-working-with-variable-names-as-parameter/m-p/697461#M213139</link>
    <description>Thank you ! it worked very well.</description>
    <pubDate>Sun, 08 Nov 2020 21:03:29 GMT</pubDate>
    <dc:creator>SASAna</dc:creator>
    <dc:date>2020-11-08T21:03:29Z</dc:date>
    <item>
      <title>prxmatch not working with variable names as parameter</title>
      <link>https://communities.sas.com/t5/SAS-Programming/prxmatch-not-working-with-variable-names-as-parameter/m-p/696759#M212873</link>
      <description>&lt;P&gt;Hi SAS users,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I need help with the below issue. proc_cd data is coming like 1234|2348 pipe delimited, and i need to check these values against excel entries ( Ex : '1234' ,'2346','5678').&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I tried this below small example with hard coded manual entry values , it worked fine. But when i pass the variable names i am getting warning and 0 observations.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Works -&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;proc sql;&lt;BR /&gt;create table total as&lt;BR /&gt;select * from test b&lt;BR /&gt;where prxmatch("!(1234|2348)!i" , '1234' ,'2346') &amp;gt; 0&lt;BR /&gt;;&lt;BR /&gt;Quit;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Does not work -&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;proc sql;&lt;BR /&gt;create table total as&lt;BR /&gt;select * from test b&lt;BR /&gt;where prxmatch("!(proc_cd)!i" , &amp;amp;proc) &amp;gt; 0&lt;BR /&gt;;&lt;BR /&gt;Quit;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;WARNING: Function PRXMATCH requires at most 2 argument(s). The extra one(s) will be ignored.&lt;/P&gt;</description>
      <pubDate>Thu, 05 Nov 2020 03:18:58 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/prxmatch-not-working-with-variable-names-as-parameter/m-p/696759#M212873</guid>
      <dc:creator>SASAna</dc:creator>
      <dc:date>2020-11-05T03:18:58Z</dc:date>
    </item>
    <item>
      <title>Re: prxmatch not working with variable names as parameter</title>
      <link>https://communities.sas.com/t5/SAS-Programming/prxmatch-not-working-with-variable-names-as-parameter/m-p/696772#M212882</link>
      <description>&lt;P&gt;1.The first query cannot possible be valid as you have 3 parameters.&lt;/P&gt;
&lt;P&gt;2.This might help:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc sql;
  create table TOTAL as
  select * from TEST 
  where prxmatch(cats("!",PROC_CD,"!i") , VAR) &amp;gt; 0;
quit;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;Parentheses are unneeded here.&lt;/P&gt;
&lt;P&gt;The i modifier is unneeded too if you only have digits to test.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 05 Nov 2020 05:05:57 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/prxmatch-not-working-with-variable-names-as-parameter/m-p/696772#M212882</guid>
      <dc:creator>ChrisNZ</dc:creator>
      <dc:date>2020-11-05T05:05:57Z</dc:date>
    </item>
    <item>
      <title>Re: prxmatch not working with variable names as parameter</title>
      <link>https://communities.sas.com/t5/SAS-Programming/prxmatch-not-working-with-variable-names-as-parameter/m-p/697461#M213139</link>
      <description>Thank you ! it worked very well.</description>
      <pubDate>Sun, 08 Nov 2020 21:03:29 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/prxmatch-not-working-with-variable-names-as-parameter/m-p/697461#M213139</guid>
      <dc:creator>SASAna</dc:creator>
      <dc:date>2020-11-08T21:03:29Z</dc:date>
    </item>
  </channel>
</rss>

