<?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 do I drop observations if one date variable is greater than another date variable? in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/How-do-I-drop-observations-if-one-date-variable-is-greater-than/m-p/275570#M55111</link>
    <description>&lt;P&gt;You are missing set-clause, therefore all&amp;nbsp;of your variables are uninitialized.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 07 Jun 2016 05:41:08 GMT</pubDate>
    <dc:creator>AskoLötjönen</dc:creator>
    <dc:date>2016-06-07T05:41:08Z</dc:date>
    <item>
      <title>How do I drop observations if one date variable is greater than another date variable?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-do-I-drop-observations-if-one-date-variable-is-greater-than/m-p/275568#M55110</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;As indicated in the subject I have 2 date variables A (format: 12DEC2012) and B (format: 20110908) in my data file. I use SAS 9.4 and the following codes, but it always shows A and B are uninitialized. I checked some information from the internet but still do not quite understand how to solve it. Is there anyone can help me figure out the problem?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Codes I use:&lt;/P&gt;&lt;P&gt;data abcd.survey;&lt;/P&gt;&lt;P&gt;if A&amp;lt;B then delete;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;</description>
      <pubDate>Tue, 07 Jun 2016 05:02:55 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-do-I-drop-observations-if-one-date-variable-is-greater-than/m-p/275568#M55110</guid>
      <dc:creator>Therain</dc:creator>
      <dc:date>2016-06-07T05:02:55Z</dc:date>
    </item>
    <item>
      <title>Re: How do I drop observations if one date variable is greater than another date variable?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-do-I-drop-observations-if-one-date-variable-is-greater-than/m-p/275570#M55111</link>
      <description>&lt;P&gt;You are missing set-clause, therefore all&amp;nbsp;of your variables are uninitialized.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 07 Jun 2016 05:41:08 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-do-I-drop-observations-if-one-date-variable-is-greater-than/m-p/275570#M55111</guid>
      <dc:creator>AskoLötjönen</dc:creator>
      <dc:date>2016-06-07T05:41:08Z</dc:date>
    </item>
    <item>
      <title>Re: How do I drop observations if one date variable is greater than another date variable?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-do-I-drop-observations-if-one-date-variable-is-greater-than/m-p/275581#M55114</link>
      <description>&lt;P&gt;As &lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/36190"&gt;@AskoLötjönen﻿&lt;/a&gt; stated, you have no data source in your data step, so A and B are not populated.&lt;/P&gt;
&lt;P&gt;You probably want&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data abcd.survey;
set abcd.survey;
if A &amp;lt; B then delete;
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 07 Jun 2016 06:33:51 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-do-I-drop-observations-if-one-date-variable-is-greater-than/m-p/275581#M55114</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2016-06-07T06:33:51Z</dc:date>
    </item>
    <item>
      <title>Re: How do I drop observations if one date variable is greater than another date variable?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-do-I-drop-observations-if-one-date-variable-is-greater-than/m-p/275713#M55168</link>
      <description>&lt;P&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/88912"&gt;@Therain&lt;/a&gt;, I am going to&amp;nbsp; assume you are relatively new to using SAS. You want to be careful with the word "format" as it has a very specific meaning related to value display. Neither of the &lt;STRONG&gt;values&lt;/STRONG&gt; you showed are formats. If the variables are SAS date valued variables then the &lt;STRONG&gt;formats&lt;/STRONG&gt; respectively would be Date9. and YYMMDD8. Please confirm by running Proc Contents on the data set that the varibles are date values with formats shown above or is A character and B simply numeric (possibly format Best8. 8.0 or similar) or character.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 07 Jun 2016 15:34:51 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-do-I-drop-observations-if-one-date-variable-is-greater-than/m-p/275713#M55168</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2016-06-07T15:34:51Z</dc:date>
    </item>
    <item>
      <title>Re: How do I drop observations if one date variable is greater than another date variable?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-do-I-drop-observations-if-one-date-variable-is-greater-than/m-p/279178#M56235</link>
      <description>&lt;P&gt;Thank you! That works very well. Yes, I am a new user of SAS and thanks for the explanation.&lt;/P&gt;</description>
      <pubDate>Wed, 22 Jun 2016 02:03:45 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-do-I-drop-observations-if-one-date-variable-is-greater-than/m-p/279178#M56235</guid>
      <dc:creator>Therain</dc:creator>
      <dc:date>2016-06-22T02:03:45Z</dc:date>
    </item>
  </channel>
</rss>

