<?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: Formatting dates in SAS Data Management</title>
    <link>https://communities.sas.com/t5/SAS-Data-Management/Formatting-dates/m-p/444640#M13719</link>
    <description>&lt;P&gt;If I understand correctly, I need to use the expression like&amp;nbsp;&lt;STRONG&gt;datepart(feemisio) &lt;/STRONG&gt;under mapping tab of the target table for the respective variable. Then I will change the format to date7. under format column of the respective variable.&lt;/P&gt;</description>
    <pubDate>Mon, 12 Mar 2018 06:00:21 GMT</pubDate>
    <dc:creator>Babloo</dc:creator>
    <dc:date>2018-03-12T06:00:21Z</dc:date>
    <item>
      <title>Formatting dates</title>
      <link>https://communities.sas.com/t5/SAS-Data-Management/Formatting-dates/m-p/444065#M13705</link>
      <description>&lt;P&gt;I've used the following code to convert the date to the format &lt;STRONG&gt;date7&lt;/STRONG&gt;. But after executing the code I'm receiving value as *******.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Variable &amp;nbsp;feemisio is a datevalue which has informats datetime23. Example:&amp;nbsp;21FEB2018:16:54:00&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc print data=temp;
format feemisio date7.;
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Appreciate if someone of you help me to resolve the issue.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 09 Mar 2018 13:12:07 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Data-Management/Formatting-dates/m-p/444065#M13705</guid>
      <dc:creator>Babloo</dc:creator>
      <dc:date>2018-03-09T13:12:07Z</dc:date>
    </item>
    <item>
      <title>Re: Formatting dates</title>
      <link>https://communities.sas.com/t5/SAS-Data-Management/Formatting-dates/m-p/444078#M13706</link>
      <description>&lt;P&gt;I guess you have already been told this repeatedly.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;You cannot use a date format on a datetime value.&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The reason being that datetime values are a &lt;EM&gt;count of seconds&lt;/EM&gt; from 1960-01-01T00:00:00, while date values are a &lt;EM&gt;count of days&lt;/EM&gt; from 1960-01-01.&lt;/P&gt;
&lt;P&gt;So, for any given date, the datetime is 86400 * date!&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If you want to convert a datetime value to a date value, use the datepart() function in the same step where you assign the date format.&lt;/P&gt;</description>
      <pubDate>Fri, 09 Mar 2018 13:49:49 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Data-Management/Formatting-dates/m-p/444078#M13706</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2018-03-09T13:49:49Z</dc:date>
    </item>
    <item>
      <title>Re: Formatting dates</title>
      <link>https://communities.sas.com/t5/SAS-Data-Management/Formatting-dates/m-p/444143#M13707</link>
      <description>&lt;P&gt;How I can deal this in SAS DI studio without using user written transformation? Will it works if I change only the format for the variable under mapping tab?&lt;/P&gt;</description>
      <pubDate>Fri, 09 Mar 2018 14:49:31 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Data-Management/Formatting-dates/m-p/444143#M13707</guid>
      <dc:creator>Babloo</dc:creator>
      <dc:date>2018-03-09T14:49:31Z</dc:date>
    </item>
    <item>
      <title>Re: Formatting dates</title>
      <link>https://communities.sas.com/t5/SAS-Data-Management/Formatting-dates/m-p/444161#M13708</link>
      <description>Again, you must separate the concept of data values and formats. &lt;BR /&gt;What &lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/11562"&gt;@Kurt_Bremser&lt;/a&gt; says is that you need to change the data value before you can apply the format required.&lt;BR /&gt;You don't need a user written transformation. You need to use a mapping expression like the datepart function. Can be used in many transformations like Table Loader, Extract and SQL Join.</description>
      <pubDate>Fri, 09 Mar 2018 15:41:36 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Data-Management/Formatting-dates/m-p/444161#M13708</guid>
      <dc:creator>LinusH</dc:creator>
      <dc:date>2018-03-09T15:41:36Z</dc:date>
    </item>
    <item>
      <title>Re: Formatting dates</title>
      <link>https://communities.sas.com/t5/SAS-Data-Management/Formatting-dates/m-p/444163#M13709</link>
      <description>&lt;P&gt;If you want to display just the date part of a datetime value you can use the DTDATE format.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;PS. Don't use width of 7. Use a width of 9 (or 11) so that you can see the century part of the year.&lt;/P&gt;</description>
      <pubDate>Fri, 09 Mar 2018 15:44:16 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Data-Management/Formatting-dates/m-p/444163#M13709</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2018-03-09T15:44:16Z</dc:date>
    </item>
    <item>
      <title>Re: Formatting dates</title>
      <link>https://communities.sas.com/t5/SAS-Data-Management/Formatting-dates/m-p/444363#M13710</link>
      <description>My requirement is see the date values in date7. Format and I have to do&lt;BR /&gt;this manipulation in DI Studio.&lt;BR /&gt;</description>
      <pubDate>Sat, 10 Mar 2018 08:28:34 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Data-Management/Formatting-dates/m-p/444363#M13710</guid>
      <dc:creator>Babloo</dc:creator>
      <dc:date>2018-03-10T08:28:34Z</dc:date>
    </item>
    <item>
      <title>Re: Formatting dates</title>
      <link>https://communities.sas.com/t5/SAS-Data-Management/Formatting-dates/m-p/444640#M13719</link>
      <description>&lt;P&gt;If I understand correctly, I need to use the expression like&amp;nbsp;&lt;STRONG&gt;datepart(feemisio) &lt;/STRONG&gt;under mapping tab of the target table for the respective variable. Then I will change the format to date7. under format column of the respective variable.&lt;/P&gt;</description>
      <pubDate>Mon, 12 Mar 2018 06:00:21 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Data-Management/Formatting-dates/m-p/444640#M13719</guid>
      <dc:creator>Babloo</dc:creator>
      <dc:date>2018-03-12T06:00:21Z</dc:date>
    </item>
    <item>
      <title>Re: Formatting dates</title>
      <link>https://communities.sas.com/t5/SAS-Data-Management/Formatting-dates/m-p/444699#M13720</link>
      <description>The best way to verify your understanding is to try it out!</description>
      <pubDate>Mon, 12 Mar 2018 10:27:01 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Data-Management/Formatting-dates/m-p/444699#M13720</guid>
      <dc:creator>LinusH</dc:creator>
      <dc:date>2018-03-12T10:27:01Z</dc:date>
    </item>
  </channel>
</rss>

