<?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: Selecting Observations in New SAS User</title>
    <link>https://communities.sas.com/t5/New-SAS-User/Selecting-Observations/m-p/599535#M16522</link>
    <description>&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data test;
input id  name$	;
datalines;
1001	 judy		
1002  louise
1003  mary  
1004  philip
1012  robert
1006  ronald
1043  thomas
1008  william
;
run;


data test1;
set test;
where id in ( 1001  1004  1012  1043);
run;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;This output like you want rejoinder me&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Sat, 26 Oct 2019 14:37:42 GMT</pubDate>
    <dc:creator>BrahmanandaRao</dc:creator>
    <dc:date>2019-10-26T14:37:42Z</dc:date>
    <item>
      <title>Selecting Observations</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Selecting-Observations/m-p/599450#M16502</link>
      <description>&lt;P&gt;Hi guys,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I know it should be a super easy question but I cannot get the results.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;ID&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Var&lt;/P&gt;&lt;P&gt;1001&lt;/P&gt;&lt;P&gt;1002&lt;/P&gt;&lt;P&gt;1003&lt;/P&gt;&lt;P&gt;1004&lt;/P&gt;&lt;P&gt;1005&lt;/P&gt;&lt;P&gt;1006&lt;/P&gt;&lt;P&gt;1007&lt;/P&gt;&lt;P&gt;.....&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I would like to select observations whose IDs are 1001, 1004,1012 and 1043. These IDs are not selected following a pattern but randomly. I tried the code below but it did not work.&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data want;
set have;
if ID = '1001';
if ID = '1004';
if ID = '1012';
if ID = '1043';
run;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;what code do I need to use? thanks!&lt;/P&gt;</description>
      <pubDate>Fri, 25 Oct 2019 20:54:19 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Selecting-Observations/m-p/599450#M16502</guid>
      <dc:creator>dapenDaniel</dc:creator>
      <dc:date>2019-10-25T20:54:19Z</dc:date>
    </item>
    <item>
      <title>Re: Selecting Observations</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Selecting-Observations/m-p/599451#M16503</link>
      <description>&lt;P&gt;HI&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/202889"&gt;@dapenDaniel&lt;/a&gt;&amp;nbsp; &amp;nbsp;Please take a look at SAS Operators specifically &lt;STRONG&gt;IN operator&lt;/STRONG&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 25 Oct 2019 20:56:59 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Selecting-Observations/m-p/599451#M16503</guid>
      <dc:creator>novinosrin</dc:creator>
      <dc:date>2019-10-25T20:56:59Z</dc:date>
    </item>
    <item>
      <title>Re: Selecting Observations</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Selecting-Observations/m-p/599452#M16504</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/138205"&gt;@novinosrin&lt;/a&gt;&amp;nbsp;Thank you!&lt;/P&gt;</description>
      <pubDate>Fri, 25 Oct 2019 21:04:07 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Selecting-Observations/m-p/599452#M16504</guid>
      <dc:creator>dapenDaniel</dc:creator>
      <dc:date>2019-10-25T21:04:07Z</dc:date>
    </item>
    <item>
      <title>Re: Selecting Observations</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Selecting-Observations/m-p/599535#M16522</link>
      <description>&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data test;
input id  name$	;
datalines;
1001	 judy		
1002  louise
1003  mary  
1004  philip
1012  robert
1006  ronald
1043  thomas
1008  william
;
run;


data test1;
set test;
where id in ( 1001  1004  1012  1043);
run;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;This output like you want rejoinder me&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 26 Oct 2019 14:37:42 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Selecting-Observations/m-p/599535#M16522</guid>
      <dc:creator>BrahmanandaRao</dc:creator>
      <dc:date>2019-10-26T14:37:42Z</dc:date>
    </item>
  </channel>
</rss>

