<?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 What to clean up a set of test scores. How would I do this using SQL? in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/What-to-clean-up-a-set-of-test-scores-How-would-I-do-this-using/m-p/770288#M244366</link>
    <description>&lt;P class="_1qeIAgB0cPwnLhDF9XSiJM"&gt;I have a dataset of test scores. My variables are (test taker’s) ID_no, test date, test score, and test type (online or in person).&lt;/P&gt;&lt;P class="_1qeIAgB0cPwnLhDF9XSiJM"&gt;Some people took the test online and in person, and therefore, are in the dataset more than once.&lt;/P&gt;&lt;P class="_1qeIAgB0cPwnLhDF9XSiJM"&gt;I’d like to make a new dataset with only those whose ID_no shows up more than once. And then with that dataset, I’d like to clean it to only include the most recent test date for each ID_no.&lt;/P&gt;&lt;P class="_1qeIAgB0cPwnLhDF9XSiJM"&gt;&amp;nbsp;&lt;/P&gt;&lt;P class="_1qeIAgB0cPwnLhDF9XSiJM"&gt;I'm not super familiar with SQL and want to develop this skill. What kind of procedure would I need to use to achieve this?&lt;/P&gt;</description>
    <pubDate>Fri, 24 Sep 2021 16:24:23 GMT</pubDate>
    <dc:creator>SAS_learneromg</dc:creator>
    <dc:date>2021-09-24T16:24:23Z</dc:date>
    <item>
      <title>What to clean up a set of test scores. How would I do this using SQL?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/What-to-clean-up-a-set-of-test-scores-How-would-I-do-this-using/m-p/770288#M244366</link>
      <description>&lt;P class="_1qeIAgB0cPwnLhDF9XSiJM"&gt;I have a dataset of test scores. My variables are (test taker’s) ID_no, test date, test score, and test type (online or in person).&lt;/P&gt;&lt;P class="_1qeIAgB0cPwnLhDF9XSiJM"&gt;Some people took the test online and in person, and therefore, are in the dataset more than once.&lt;/P&gt;&lt;P class="_1qeIAgB0cPwnLhDF9XSiJM"&gt;I’d like to make a new dataset with only those whose ID_no shows up more than once. And then with that dataset, I’d like to clean it to only include the most recent test date for each ID_no.&lt;/P&gt;&lt;P class="_1qeIAgB0cPwnLhDF9XSiJM"&gt;&amp;nbsp;&lt;/P&gt;&lt;P class="_1qeIAgB0cPwnLhDF9XSiJM"&gt;I'm not super familiar with SQL and want to develop this skill. What kind of procedure would I need to use to achieve this?&lt;/P&gt;</description>
      <pubDate>Fri, 24 Sep 2021 16:24:23 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/What-to-clean-up-a-set-of-test-scores-How-would-I-do-this-using/m-p/770288#M244366</guid>
      <dc:creator>SAS_learneromg</dc:creator>
      <dc:date>2021-09-24T16:24:23Z</dc:date>
    </item>
    <item>
      <title>Re: What to clean up a set of test scores. How would I do this using SQL?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/What-to-clean-up-a-set-of-test-scores-How-would-I-do-this-using/m-p/770291#M244368</link>
      <description>&lt;P&gt;Assuming that the people who took the test online and in person did not do this both on the same day, this should work&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc sql;
     create table want as select * from have
     group by ID_no
     having test_date=max(test_date);
quit;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 24 Sep 2021 16:30:06 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/What-to-clean-up-a-set-of-test-scores-How-would-I-do-this-using/m-p/770291#M244368</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2021-09-24T16:30:06Z</dc:date>
    </item>
    <item>
      <title>Re: What to clean up a set of test scores. How would I do this using SQL?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/What-to-clean-up-a-set-of-test-scores-How-would-I-do-this-using/m-p/770295#M244371</link>
      <description>Written on my smartphone here comes a possible solution that you could try.&lt;BR /&gt;Proc Sort data=have;&lt;BR /&gt;By id_no test_date;&lt;BR /&gt;Run;&lt;BR /&gt;&lt;BR /&gt;Data want;&lt;BR /&gt;Set have;&lt;BR /&gt;By id_no test_date;&lt;BR /&gt;If first.id_no &amp;lt;&amp;gt; last.id_no;&lt;BR /&gt;Call missing(test_score);&lt;BR /&gt;Run;</description>
      <pubDate>Fri, 24 Sep 2021 16:34:26 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/What-to-clean-up-a-set-of-test-scores-How-would-I-do-this-using/m-p/770295#M244371</guid>
      <dc:creator>acordes</dc:creator>
      <dc:date>2021-09-24T16:34:26Z</dc:date>
    </item>
    <item>
      <title>Re: What to clean up a set of test scores. How would I do this using SQL?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/What-to-clean-up-a-set-of-test-scores-How-would-I-do-this-using/m-p/770297#M244373</link>
      <description>Yes, that's exactly what I needed to. Thank you!</description>
      <pubDate>Fri, 24 Sep 2021 16:42:03 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/What-to-clean-up-a-set-of-test-scores-How-would-I-do-this-using/m-p/770297#M244373</guid>
      <dc:creator>SAS_learneromg</dc:creator>
      <dc:date>2021-09-24T16:42:03Z</dc:date>
    </item>
  </channel>
</rss>

