<?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: Calculate dates. in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Calculate-dates/m-p/69768#M15111</link>
    <description>Creating a new SAS variable is basic DATA step programming with SAS.  What code, if any, have you tried?  Can you share that code for feedback?  If you need to assign a new variable, you can do so in a SAS DATA step and since the variable is a DATE, you will want to assign a FORMAT statement to the variable (or use a singe ATTRIB statement).&lt;BR /&gt;
&lt;BR /&gt;
I have provided a SAS-hosted documentation link below -- also, the SAS support  &lt;A href="http://support.sas.com/" target="_blank"&gt;http://support.sas.com/&lt;/A&gt;  website has very useful information as technical and conference topic-related references, which you can find using the SEARCH facility.&lt;BR /&gt;
&lt;BR /&gt;
Scott Barry&lt;BR /&gt;
SBBWorks, Inc.&lt;BR /&gt;
&lt;BR /&gt;
Introduction to DATA Step Processing&lt;BR /&gt;
&lt;A href="http://support.sas.com/documentation/cdl/en/basess/58133/HTML/default/a001302699.htm" target="_blank"&gt;http://support.sas.com/documentation/cdl/en/basess/58133/HTML/default/a001302699.htm&lt;/A&gt;</description>
    <pubDate>Tue, 08 Sep 2009 12:56:38 GMT</pubDate>
    <dc:creator>sbb</dc:creator>
    <dc:date>2009-09-08T12:56:38Z</dc:date>
    <item>
      <title>Calculate dates.</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Calculate-dates/m-p/69765#M15108</link>
      <description>Image i have a table like that:&lt;BR /&gt;
&lt;BR /&gt;
cod         date                mov           term_date          begin_date&lt;BR /&gt;
 1       24MAY2009            0                   .                         .&lt;BR /&gt;
 1       25MAY2009            1                   .                25MAY2009&lt;BR /&gt;
 1       26MAY2009            0                   .                         .             &lt;BR /&gt;
 1       27MAY2009            2                   .                         .             &lt;BR /&gt;
 1       28MAY2009            0                   .                         .             &lt;BR /&gt;
 1       29MAY2009            1            29MAY2009               .  &lt;BR /&gt;
 1       30MAY2009            1                   .                         .&lt;BR /&gt;
&lt;BR /&gt;
I want to extract the data set that is between the variable begin_date and term_date and to fill out it with the existent dates in the variable dates. &lt;BR /&gt;
&lt;BR /&gt;
How can i do it? Thanks</description>
      <pubDate>Mon, 07 Sep 2009 22:06:39 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Calculate-dates/m-p/69765#M15108</guid>
      <dc:creator>deleted_user</dc:creator>
      <dc:date>2009-09-07T22:06:39Z</dc:date>
    </item>
    <item>
      <title>Re: Calculate dates.</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Calculate-dates/m-p/69766#M15109</link>
      <description>Your request has multiple interpretations.  Perhaps you could show what you wnt the ending dataset to look like.</description>
      <pubDate>Tue, 08 Sep 2009 01:21:16 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Calculate-dates/m-p/69766#M15109</guid>
      <dc:creator>Doc_Duke</dc:creator>
      <dc:date>2009-09-08T01:21:16Z</dc:date>
    </item>
    <item>
      <title>Re: Calculate dates.</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Calculate-dates/m-p/69767#M15110</link>
      <description>Hi all,&lt;BR /&gt;
&lt;BR /&gt;
I want this final dataset:&lt;BR /&gt;
&lt;BR /&gt;
cod date mov term_date begin_date new_variable&lt;BR /&gt;
1 25MAY2009 1 . 25MAY2009          25MAY2009&lt;BR /&gt;
1 26MAY2009 0 . .                           26MAY2009&lt;BR /&gt;
1 27MAY2009 2 . .                           27MAY2009&lt;BR /&gt;
1 28MAY2009 0 . .                           28MAY2009&lt;BR /&gt;
1 29MAY2009 1 29MAY2009 .          29MAY2009&lt;BR /&gt;
&lt;BR /&gt;
I try to use first and last procedure but i need to have this output at new_variable.&lt;BR /&gt;
&lt;BR /&gt;
Thanks</description>
      <pubDate>Tue, 08 Sep 2009 09:44:36 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Calculate-dates/m-p/69767#M15110</guid>
      <dc:creator>deleted_user</dc:creator>
      <dc:date>2009-09-08T09:44:36Z</dc:date>
    </item>
    <item>
      <title>Re: Calculate dates.</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Calculate-dates/m-p/69768#M15111</link>
      <description>Creating a new SAS variable is basic DATA step programming with SAS.  What code, if any, have you tried?  Can you share that code for feedback?  If you need to assign a new variable, you can do so in a SAS DATA step and since the variable is a DATE, you will want to assign a FORMAT statement to the variable (or use a singe ATTRIB statement).&lt;BR /&gt;
&lt;BR /&gt;
I have provided a SAS-hosted documentation link below -- also, the SAS support  &lt;A href="http://support.sas.com/" target="_blank"&gt;http://support.sas.com/&lt;/A&gt;  website has very useful information as technical and conference topic-related references, which you can find using the SEARCH facility.&lt;BR /&gt;
&lt;BR /&gt;
Scott Barry&lt;BR /&gt;
SBBWorks, Inc.&lt;BR /&gt;
&lt;BR /&gt;
Introduction to DATA Step Processing&lt;BR /&gt;
&lt;A href="http://support.sas.com/documentation/cdl/en/basess/58133/HTML/default/a001302699.htm" target="_blank"&gt;http://support.sas.com/documentation/cdl/en/basess/58133/HTML/default/a001302699.htm&lt;/A&gt;</description>
      <pubDate>Tue, 08 Sep 2009 12:56:38 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Calculate-dates/m-p/69768#M15111</guid>
      <dc:creator>sbb</dc:creator>
      <dc:date>2009-09-08T12:56:38Z</dc:date>
    </item>
  </channel>
</rss>

