<?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 Help for REGEX in SAS Data Science</title>
    <link>https://communities.sas.com/t5/SAS-Data-Science/Help-for-REGEX/m-p/981853#M11105</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;I am a beginner in Regex and it's very difficult to understand some errors. I want to find 30 kms or 30 km, or 30 kilometers&amp;nbsp;&lt;/P&gt;
&lt;DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;REGEX&lt;/SPAN&gt;&lt;SPAN&gt;: [0-9][0-9] km(s)?.&amp;nbsp;&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;I Try with that only for km or kms but I have always a error with a escape character and I don't understand when I have to add this one.&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;/DIV&gt;</description>
    <pubDate>Mon, 12 Jan 2026 23:24:18 GMT</pubDate>
    <dc:creator>YannRC</dc:creator>
    <dc:date>2026-01-12T23:24:18Z</dc:date>
    <item>
      <title>Help for REGEX</title>
      <link>https://communities.sas.com/t5/SAS-Data-Science/Help-for-REGEX/m-p/981853#M11105</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;I am a beginner in Regex and it's very difficult to understand some errors. I want to find 30 kms or 30 km, or 30 kilometers&amp;nbsp;&lt;/P&gt;
&lt;DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;REGEX&lt;/SPAN&gt;&lt;SPAN&gt;: [0-9][0-9] km(s)?.&amp;nbsp;&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;I Try with that only for km or kms but I have always a error with a escape character and I don't understand when I have to add this one.&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;/DIV&gt;</description>
      <pubDate>Mon, 12 Jan 2026 23:24:18 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Data-Science/Help-for-REGEX/m-p/981853#M11105</guid>
      <dc:creator>YannRC</dc:creator>
      <dc:date>2026-01-12T23:24:18Z</dc:date>
    </item>
    <item>
      <title>Re: Help for REGEX</title>
      <link>https://communities.sas.com/t5/SAS-Data-Science/Help-for-REGEX/m-p/981855#M11106</link>
      <description>&lt;P&gt;Can you provide more details of what you have tried?&lt;BR /&gt;Are you trying to write CODE?&amp;nbsp; If so show the code.&amp;nbsp; Provide some example input data and the expected result.&lt;/P&gt;
&lt;P&gt;Are you trying to use REGEX is some other place? Explain where.&amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Be specific about the environment you are using and the version of SAS you are using and version of any front end tools like Enterprise Guide or SAS/Studio.&lt;/P&gt;</description>
      <pubDate>Tue, 13 Jan 2026 01:07:44 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Data-Science/Help-for-REGEX/m-p/981855#M11106</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2026-01-13T01:07:44Z</dc:date>
    </item>
    <item>
      <title>Re: Help for REGEX</title>
      <link>https://communities.sas.com/t5/SAS-Data-Science/Help-for-REGEX/m-p/981861#M11107</link>
      <description>&lt;P&gt;Add some sample data would be very helpful to understand your question.&lt;/P&gt;
&lt;P&gt;Here you go.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data x;
input x $80.;
if prxmatch('/\d+\s*(km|kms|kilometers)/i',x) then match=1;
 else match=0;
cards;
I want to find 30 kms 
I want to find 30 km, 
I want to find 30 kilometers 
I want to find kilometers 
;




&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Ksharp_0-1768271850308.png" style="width: 400px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/112588i46B56A359421684B/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Ksharp_0-1768271850308.png" alt="Ksharp_0-1768271850308.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 13 Jan 2026 02:37:44 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Data-Science/Help-for-REGEX/m-p/981861#M11107</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2026-01-13T02:37:44Z</dc:date>
    </item>
    <item>
      <title>Re: Help for REGEX</title>
      <link>https://communities.sas.com/t5/SAS-Data-Science/Help-for-REGEX/m-p/981862#M11108</link>
      <description>And could try this:&lt;BR /&gt;REGEX: [0-9][0-9] kms?&lt;BR /&gt;If you need to match dot ,you need to add escape char '\':&lt;BR /&gt;REGEX: [0-9][0-9] kms?\.</description>
      <pubDate>Tue, 13 Jan 2026 02:43:13 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Data-Science/Help-for-REGEX/m-p/981862#M11108</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2026-01-13T02:43:13Z</dc:date>
    </item>
  </channel>
</rss>

