<?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: Search where in Discussions</title>
    <link>https://community.jmp.com/t5/Discussions/Search-where/m-p/418724#M66772</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.jmp.com/t5/user/viewprofilepage/user-id/2687"&gt;@txnelson&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Still not working. Thoughts?&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Names Default To Here( 1 );
Clear Globals();
Clear log();

dt = Open("$SAMPLE_DATA/Water Treatment.jmp");
dt &amp;lt;&amp;lt; Clear Column Selection();
Col_List = dt &amp;lt;&amp;lt; Get Column Names("String");
list = {};
for(u = 1, u &amp;lt;= N Items(Col_List),u++,
If(Contains(Col_List[u], "SED-E"),
Column(Col_List[u]) &amp;lt;&amp;lt; Set Selected (1);
	Insert Into(list, Col_List[u]),
);
);
dt &amp;lt;&amp;lt; Select where(Column(Eval(list)) &amp;gt; 6)&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Thu, 16 Sep 2021 14:56:23 GMT</pubDate>
    <dc:creator>Jackie_</dc:creator>
    <dc:date>2021-09-16T14:56:23Z</dc:date>
    <item>
      <title>Search where</title>
      <link>https://community.jmp.com/t5/Discussions/Search-where/m-p/418651#M66767</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I want to select all rows containing value &amp;gt; 5. In the following script I used for, if and contain statement to select columns containing string "SE" and to highlight row containing values &amp;gt; 5 from the selected column I used the select where( Row() &amp;gt; 5) but doesn't work.&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Names Default To Here( 1 );
Clear Globals();
Clear log();

dt = Open("$SAMPLE_DATA/Water Treatment.jmp");
dt &amp;lt;&amp;lt; Clear Column Selection();
Col_List = dt &amp;lt;&amp;lt; Get Column Names("String");

for(u = 1, u &amp;lt;= N Items(Col_List),u++,
If(Contains(Col_List[u], "SE"),
 Column(Col_List[u]) &amp;lt;&amp;lt; Set Selected(1);
 
);
);
dt &amp;lt;&amp;lt; Select where( Row() &amp;gt; 5);
 &lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 09 Jun 2023 19:56:50 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Search-where/m-p/418651#M66767</guid>
      <dc:creator>Jackie_</dc:creator>
      <dc:date>2023-06-09T19:56:50Z</dc:date>
    </item>
    <item>
      <title>Re: Search where</title>
      <link>https://community.jmp.com/t5/Discussions/Search-where/m-p/418662#M66768</link>
      <description>&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;dt &amp;lt;&amp;lt; Select where( Row() &amp;gt; 5);&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;is specifying to select all rows, where the row number(row()) is greater than 5.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;What you need to do is to replace Row() with the column whos values you want to&amp;nbsp; select if greater than 5.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Check out the documentation on Select Where() in the Scripting Index.&amp;nbsp;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 16 Sep 2021 13:14:30 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Search-where/m-p/418662#M66768</guid>
      <dc:creator>txnelson</dc:creator>
      <dc:date>2021-09-16T13:14:30Z</dc:date>
    </item>
    <item>
      <title>Re: Search where</title>
      <link>https://community.jmp.com/t5/Discussions/Search-where/m-p/418724#M66772</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.jmp.com/t5/user/viewprofilepage/user-id/2687"&gt;@txnelson&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Still not working. Thoughts?&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Names Default To Here( 1 );
Clear Globals();
Clear log();

dt = Open("$SAMPLE_DATA/Water Treatment.jmp");
dt &amp;lt;&amp;lt; Clear Column Selection();
Col_List = dt &amp;lt;&amp;lt; Get Column Names("String");
list = {};
for(u = 1, u &amp;lt;= N Items(Col_List),u++,
If(Contains(Col_List[u], "SED-E"),
Column(Col_List[u]) &amp;lt;&amp;lt; Set Selected (1);
	Insert Into(list, Col_List[u]),
);
);
dt &amp;lt;&amp;lt; Select where(Column(Eval(list)) &amp;gt; 6)&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 16 Sep 2021 14:56:23 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Search-where/m-p/418724#M66772</guid>
      <dc:creator>Jackie_</dc:creator>
      <dc:date>2021-09-16T14:56:23Z</dc:date>
    </item>
    <item>
      <title>Re: Search where</title>
      <link>https://community.jmp.com/t5/Discussions/Search-where/m-p/418739#M66774</link>
      <description>&lt;P&gt;It worked&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Names Default To Here( 1 );
Clear Globals();
Clear log();

dt = Open("$SAMPLE_DATA/Water Treatment.jmp");
dt &amp;lt;&amp;lt; Clear Column Selection();
Col_List = dt &amp;lt;&amp;lt; Get Column Names("String");
list = {};
for(u = 1, u &amp;lt;= N Items(Col_List),u++,
If(Contains(Col_List[u], "ZN"),
Column(Col_List[u]) &amp;lt;&amp;lt; Set Selected (1);
	Insert Into(list, Col_List[u]),
);
);

dt &amp;lt;&amp;lt; Select where(as column(list) &amp;gt; 5 );&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 16 Sep 2021 15:48:19 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Search-where/m-p/418739#M66774</guid>
      <dc:creator>Jackie_</dc:creator>
      <dc:date>2021-09-16T15:48:19Z</dc:date>
    </item>
    <item>
      <title>Re: Search where</title>
      <link>https://community.jmp.com/t5/Discussions/Search-where/m-p/418768#M66780</link>
      <description>&lt;P&gt;Your solution will only work if only one column is found when you use the&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;If(Contains(Col_List[u], "ZN"),&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;If you use:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;If(Contains(Col_List[u], "SS"),&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;and set the select to&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;dt &amp;lt;&amp;lt; Select where(as column(list) &amp;gt; 179);&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;you will see that the rows are selected based upon only the first column in your "list"&lt;/P&gt;</description>
      <pubDate>Thu, 16 Sep 2021 16:47:33 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Search-where/m-p/418768#M66780</guid>
      <dc:creator>txnelson</dc:creator>
      <dc:date>2021-09-16T16:47:33Z</dc:date>
    </item>
  </channel>
</rss>

