<?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: Data Logic in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Data-Logic/m-p/414542#M101569</link>
    <description>&lt;P&gt;A simple variation on Tom's program handles both cases:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;data want;&lt;/P&gt;
&lt;P&gt;set have;&lt;/P&gt;
&lt;P&gt;output;&lt;/P&gt;
&lt;P&gt;if _n_=1 and text='yyy' then stop;&lt;/P&gt;
&lt;P&gt;run;&lt;/P&gt;</description>
    <pubDate>Fri, 17 Nov 2017 21:39:26 GMT</pubDate>
    <dc:creator>Astounding</dc:creator>
    <dc:date>2017-11-17T21:39:26Z</dc:date>
    <item>
      <title>Data Logic</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Data-Logic/m-p/414525#M101564</link>
      <description>&lt;P&gt;&lt;BR /&gt;All,&lt;/P&gt;
&lt;P&gt;I have the following dataset, if the value of the 1st observation in column text is "yyy" then output only first obs or else output all the &lt;BR /&gt;observation from the datasets&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;Case 1&lt;/P&gt;
&lt;P&gt;have &lt;BR /&gt;text id1 id2 id3&lt;BR /&gt;yyy 123 145 345&lt;BR /&gt;zzz 899 134 878&lt;BR /&gt;ccc 881 jk kjk&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;want &lt;BR /&gt;text id1 id2 id3&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;Case 2&lt;/P&gt;
&lt;P&gt;have &lt;BR /&gt;text id1 id2 id3&lt;BR /&gt;mmm 123 145 345&lt;BR /&gt;zzz 899 134 878&lt;BR /&gt;ccc 881 jk kjk&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;want&lt;BR /&gt;text id1 id2 id3&lt;BR /&gt;mmm 123 145 345&lt;BR /&gt;zzz 899 134 878&lt;BR /&gt;ccc 881 jk kjk&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;Thanks &lt;BR /&gt;Al&lt;/P&gt;</description>
      <pubDate>Fri, 17 Nov 2017 20:03:38 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Data-Logic/m-p/414525#M101564</guid>
      <dc:creator>Almoha</dc:creator>
      <dc:date>2017-11-17T20:03:38Z</dc:date>
    </item>
    <item>
      <title>Re: Data Logic</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Data-Logic/m-p/414528#M101565</link>
      <description>&lt;P&gt;It doesn't look like you want to output ANY observations.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data want ;
  set have ;
  if _n_=1 and text='yyy' then stop;
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 17 Nov 2017 20:21:07 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Data-Logic/m-p/414528#M101565</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2017-11-17T20:21:07Z</dc:date>
    </item>
    <item>
      <title>Re: Data Logic</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Data-Logic/m-p/414537#M101568</link>
      <description>&lt;P&gt;sorry i do &amp;nbsp;.. my mistake ..&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;i want the following dataset with only 1st obs if text="yyy"&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;text id1 id2 id3&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;yyy 123 145 345&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 17 Nov 2017 21:06:53 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Data-Logic/m-p/414537#M101568</guid>
      <dc:creator>Almoha</dc:creator>
      <dc:date>2017-11-17T21:06:53Z</dc:date>
    </item>
    <item>
      <title>Re: Data Logic</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Data-Logic/m-p/414542#M101569</link>
      <description>&lt;P&gt;A simple variation on Tom's program handles both cases:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;data want;&lt;/P&gt;
&lt;P&gt;set have;&lt;/P&gt;
&lt;P&gt;output;&lt;/P&gt;
&lt;P&gt;if _n_=1 and text='yyy' then stop;&lt;/P&gt;
&lt;P&gt;run;&lt;/P&gt;</description>
      <pubDate>Fri, 17 Nov 2017 21:39:26 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Data-Logic/m-p/414542#M101569</guid>
      <dc:creator>Astounding</dc:creator>
      <dc:date>2017-11-17T21:39:26Z</dc:date>
    </item>
  </channel>
</rss>

