<?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 records from one data set that aren't in another in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Selecting-records-from-one-data-set-that-aren-t-in-another/m-p/627442#M185236</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/194609"&gt;@tmes&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In addition to&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/12447"&gt;@Patrick&lt;/a&gt;&amp;nbsp;'s comment, I wonder if lunch or times datasets have only one or many records per&amp;nbsp;&lt;SPAN&gt;person_id&lt;/SPAN&gt;?&lt;/P&gt;
&lt;P&gt;In case there are many, maybe you need to suppress duplicate records to retrieve unique IDs.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best,&lt;/P&gt;</description>
    <pubDate>Wed, 26 Feb 2020 09:05:29 GMT</pubDate>
    <dc:creator>ed_sas_member</dc:creator>
    <dc:date>2020-02-26T09:05:29Z</dc:date>
    <item>
      <title>Selecting records from one data set that aren't in another</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Selecting-records-from-one-data-set-that-aren-t-in-another/m-p/627367#M185186</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;So I'm working in EG 7.1 and I have a dataset with over 4 million records and another dataset with around 200,000 records. For explanation purposes I'll call them lunch and time, respectively.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I need to output all the person_ids from lunch that aren't in time. I have tried the following -&amp;nbsp;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;proc sql;&lt;BR /&gt;create table lunchtime as&lt;BR /&gt;select *&lt;BR /&gt;from lunch t1&lt;BR /&gt;where person_id not in (select person_id from time);&lt;BR /&gt;quit;&lt;/LI&gt;&lt;LI&gt;Proc SQL except function&lt;/LI&gt;&lt;LI&gt;Left Join&lt;/LI&gt;&lt;LI&gt;If in a and not b function&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;Functionally, the code works. It's outputting around 3 million records which makes sense, however the result I need to get to is approx. 150,000. At this point I'm thinking that there's something my boss has forgotten to tell me about the data, however I was just wondering if anyone has any other ideas on how to do this?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks in advance.&lt;/P&gt;</description>
      <pubDate>Wed, 26 Feb 2020 01:22:14 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Selecting-records-from-one-data-set-that-aren-t-in-another/m-p/627367#M185186</guid>
      <dc:creator>tmes</dc:creator>
      <dc:date>2020-02-26T01:22:14Z</dc:date>
    </item>
    <item>
      <title>Re: Selecting records from one data set that aren't in another</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Selecting-records-from-one-data-set-that-aren-t-in-another/m-p/627372#M185189</link>
      <description>&lt;P&gt;If I understand this right then you've used multiple coding approaches for combining the data and you've always got the same result. Looks very much like your boss didn't tell you something - or the data is different from what your boss thinks it is.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;May be run a proc freq over your lunch dataset to see if there are some DQ issues like a few matching id's with very high (too high) volumes.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 26 Feb 2020 01:48:06 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Selecting-records-from-one-data-set-that-aren-t-in-another/m-p/627372#M185189</guid>
      <dc:creator>Patrick</dc:creator>
      <dc:date>2020-02-26T01:48:06Z</dc:date>
    </item>
    <item>
      <title>Re: Selecting records from one data set that aren't in another</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Selecting-records-from-one-data-set-that-aren-t-in-another/m-p/627442#M185236</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/194609"&gt;@tmes&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In addition to&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/12447"&gt;@Patrick&lt;/a&gt;&amp;nbsp;'s comment, I wonder if lunch or times datasets have only one or many records per&amp;nbsp;&lt;SPAN&gt;person_id&lt;/SPAN&gt;?&lt;/P&gt;
&lt;P&gt;In case there are many, maybe you need to suppress duplicate records to retrieve unique IDs.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best,&lt;/P&gt;</description>
      <pubDate>Wed, 26 Feb 2020 09:05:29 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Selecting-records-from-one-data-set-that-aren-t-in-another/m-p/627442#M185236</guid>
      <dc:creator>ed_sas_member</dc:creator>
      <dc:date>2020-02-26T09:05:29Z</dc:date>
    </item>
  </channel>
</rss>

