<?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: How can select data based on the value of another data table? in Discussions</title>
    <link>https://community.jmp.com/t5/Discussions/How-can-select-data-based-on-the-value-of-another-data-table/m-p/274901#M53331</link>
    <description>&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;d1 = Current Data Table();
d2 = Open( "$SAMPLE_DATA/Big Class.jmp" );
d2 &amp;lt;&amp;lt; Update( With( d1 ), Match Columns( :age = :age ), Add Columns from Update table( :col ) );
d2 &amp;lt;&amp;lt; Select Where( :col &amp;gt; 0 );
d3 = d2 &amp;lt;&amp;lt; Subset( Output Table( "test" ), Selected Rows( 1 ), selected columns( 0 ) );&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;SPAN&gt;That's all I can do.&lt;/SPAN&gt;&lt;/P&gt;</description>
    <pubDate>Tue, 23 Jun 2020 09:28:22 GMT</pubDate>
    <dc:creator>lwx228</dc:creator>
    <dc:date>2020-06-23T09:28:22Z</dc:date>
    <item>
      <title>How can select data based on the value of another data table?</title>
      <link>https://community.jmp.com/t5/Discussions/How-can-select-data-based-on-the-value-of-another-data-table/m-p/274854#M53318</link>
      <description>&lt;P&gt;For example, using the "Big class.jMP "data, select the number of rows whose "age" corresponds to the value of another table.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="2020-06-23_11-53.png" style="width: 743px;"&gt;&lt;img src="https://community.jmp.com/t5/image/serverpage/image-id/24754i20A44EA324F75584/image-size/large?v=v2&amp;amp;px=999" role="button" title="2020-06-23_11-53.png" alt="2020-06-23_11-53.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;</description>
      <pubDate>Fri, 09 Jun 2023 23:30:00 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-can-select-data-based-on-the-value-of-another-data-table/m-p/274854#M53318</guid>
      <dc:creator>lala</dc:creator>
      <dc:date>2023-06-09T23:30:00Z</dc:date>
    </item>
    <item>
      <title>Re: How can select data based on the value of another data table?</title>
      <link>https://community.jmp.com/t5/Discussions/How-can-select-data-based-on-the-value-of-another-data-table/m-p/274867#M53320</link>
      <description>&lt;P&gt;Here is a simple example to do the selections you want&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA/big class.jmp" );

// Create the config table
dtCon = New Table( "Config", New Column( "Col", values( {13, 15} ) ) );

// Select the data based upon the values in the Config table
dt &amp;lt;&amp;lt; clear select;
For( i = 1, i &amp;lt;= N Rows( dtCon ), i++,
	dt &amp;lt;&amp;lt; select where( :age == dtCon:Col[i], current selection( "extend" ) )
);&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 23 Jun 2020 05:16:48 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-can-select-data-based-on-the-value-of-another-data-table/m-p/274867#M53320</guid>
      <dc:creator>txnelson</dc:creator>
      <dc:date>2020-06-23T05:16:48Z</dc:date>
    </item>
    <item>
      <title>Re: How can select data based on the value of another data table?</title>
      <link>https://community.jmp.com/t5/Discussions/How-can-select-data-based-on-the-value-of-another-data-table/m-p/274899#M53329</link>
      <description>Thank Jim!&lt;BR /&gt;&lt;BR /&gt;Again, There going to use the loop.</description>
      <pubDate>Tue, 23 Jun 2020 06:34:23 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-can-select-data-based-on-the-value-of-another-data-table/m-p/274899#M53329</guid>
      <dc:creator>lala</dc:creator>
      <dc:date>2020-06-23T06:34:23Z</dc:date>
    </item>
    <item>
      <title>Re: How can select data based on the value of another data table?</title>
      <link>https://community.jmp.com/t5/Discussions/How-can-select-data-based-on-the-value-of-another-data-table/m-p/274901#M53331</link>
      <description>&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;d1 = Current Data Table();
d2 = Open( "$SAMPLE_DATA/Big Class.jmp" );
d2 &amp;lt;&amp;lt; Update( With( d1 ), Match Columns( :age = :age ), Add Columns from Update table( :col ) );
d2 &amp;lt;&amp;lt; Select Where( :col &amp;gt; 0 );
d3 = d2 &amp;lt;&amp;lt; Subset( Output Table( "test" ), Selected Rows( 1 ), selected columns( 0 ) );&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;SPAN&gt;That's all I can do.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 23 Jun 2020 09:28:22 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-can-select-data-based-on-the-value-of-another-data-table/m-p/274901#M53331</guid>
      <dc:creator>lwx228</dc:creator>
      <dc:date>2020-06-23T09:28:22Z</dc:date>
    </item>
  </channel>
</rss>

