<?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: Extracting characters within certian pattern including square brackets in Discussions</title>
    <link>https://community.jmp.com/t5/Discussions/Extracting-characters-within-certian-pattern-including-square/m-p/827636#M100938</link>
    <description>&lt;P&gt;Thank you. This works perfect. Could you please explain why "$" is in the code?&lt;/P&gt;</description>
    <pubDate>Thu, 16 Jan 2025 17:28:39 GMT</pubDate>
    <dc:creator>eugur</dc:creator>
    <dc:date>2025-01-16T17:28:39Z</dc:date>
    <item>
      <title>Extracting characters within certian pattern including square brackets</title>
      <link>https://community.jmp.com/t5/Discussions/Extracting-characters-within-certian-pattern-including-square/m-p/827623#M100935</link>
      <description>&lt;P&gt;Hi,&lt;BR /&gt;I have want to extract information from a text in a table row that includes square brackets.&lt;BR /&gt;Example Rows in text column:&lt;BR /&gt;Plate[QWE147] Reg[ABC123]&lt;BR /&gt;Plate[ASD258] Reg[DEF456]&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Information I want to extract:&lt;BR /&gt;ABC123&lt;/P&gt;&lt;P&gt;DEF456&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;What is the best way to do this? I wanted to do it with regex but square brackets makes it complicated.&lt;/P&gt;</description>
      <pubDate>Thu, 16 Jan 2025 16:46:45 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Extracting-characters-within-certian-pattern-including-square/m-p/827623#M100935</guid>
      <dc:creator>eugur</dc:creator>
      <dc:date>2025-01-16T16:46:45Z</dc:date>
    </item>
    <item>
      <title>Re: Extracting characters within certian pattern including square brackets</title>
      <link>https://community.jmp.com/t5/Discussions/Extracting-characters-within-certian-pattern-including-square/m-p/827634#M100936</link>
      <description>&lt;P&gt;You have to do some escaping&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Names Default To Here(1);

str1 = "Plate[QWE147] Reg[ABC123]";
str2 = "Plate[ASD258] Reg[DEF456]";

Show(Regex(str1, "Reg\!\[(.+)]$", "\1"));
Show(Regex(str2, "Reg\!\[(.+)]$", "\1"));&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&lt;CODE class=" language-jsl"&gt;&lt;/CODE&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 16 Jan 2025 17:03:48 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Extracting-characters-within-certian-pattern-including-square/m-p/827634#M100936</guid>
      <dc:creator>jthi</dc:creator>
      <dc:date>2025-01-16T17:03:48Z</dc:date>
    </item>
    <item>
      <title>Re: Extracting characters within certian pattern including square brackets</title>
      <link>https://community.jmp.com/t5/Discussions/Extracting-characters-within-certian-pattern-including-square/m-p/827635#M100937</link>
      <description>&lt;P&gt;Also using Word(-1,...) might be enough if your strings are simple enough&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Names Default To Here(1);

str1 = "Plate[QWE147] Reg[ABC123]";
str2 = "Plate[ASD258] Reg[DEF456]";

Show(Word(-1, str1, "[]")); // Word(-1, str1, "[]") = "ABC123";
Show(Word(-1, str2, "[]")); // Word(-1, str2, "[]") = "DEF456";&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 16 Jan 2025 17:19:55 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Extracting-characters-within-certian-pattern-including-square/m-p/827635#M100937</guid>
      <dc:creator>jthi</dc:creator>
      <dc:date>2025-01-16T17:19:55Z</dc:date>
    </item>
    <item>
      <title>Re: Extracting characters within certian pattern including square brackets</title>
      <link>https://community.jmp.com/t5/Discussions/Extracting-characters-within-certian-pattern-including-square/m-p/827636#M100938</link>
      <description>&lt;P&gt;Thank you. This works perfect. Could you please explain why "$" is in the code?&lt;/P&gt;</description>
      <pubDate>Thu, 16 Jan 2025 17:28:39 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Extracting-characters-within-certian-pattern-including-square/m-p/827636#M100938</guid>
      <dc:creator>eugur</dc:creator>
      <dc:date>2025-01-16T17:28:39Z</dc:date>
    </item>
    <item>
      <title>Re: Extracting characters within certian pattern including square brackets</title>
      <link>https://community.jmp.com/t5/Discussions/Extracting-characters-within-certian-pattern-including-square/m-p/827637#M100939</link>
      <description>&lt;P&gt;Most likely unnecessary, but it just tries to make sure it matches at the end&lt;/P&gt;</description>
      <pubDate>Thu, 16 Jan 2025 18:46:15 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Extracting-characters-within-certian-pattern-including-square/m-p/827637#M100939</guid>
      <dc:creator>jthi</dc:creator>
      <dc:date>2025-01-16T18:46:15Z</dc:date>
    </item>
    <item>
      <title>Re: Extracting characters within certian pattern including square brackets</title>
      <link>https://community.jmp.com/t5/Discussions/Extracting-characters-within-certian-pattern-including-square/m-p/827659#M100942</link>
      <description>&lt;P&gt;You can also use the word function:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Names Default To Here(1);
str1 = "Plate[QWE147] Reg[ABC123]";
str2 = "Plate[ASD258] Reg[DEF456]";
show(word(4, str1, "[]"));
show(word(4, str2, "[]"));&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 16 Jan 2025 19:54:47 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Extracting-characters-within-certian-pattern-including-square/m-p/827659#M100942</guid>
      <dc:creator>pmroz</dc:creator>
      <dc:date>2025-01-16T19:54:47Z</dc:date>
    </item>
  </channel>
</rss>

