<?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: name of day in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/name-of-day/m-p/618796#M181570</link>
    <description>&lt;P&gt;nameday is defined numeric in the first data step; trying to assign it a character value will result in missing values and the corresponding NOTEs in the log.&lt;/P&gt;
&lt;P&gt;Maxim 2: Read the Log:&lt;/P&gt;
&lt;PRE&gt;54         data RawTbl2 ;
55         set RawTbl;
56         nameDay=put(date1,dowName.) ;
57         run;
NOTE: Character values have been converted to numeric values at the places given by: (Line):(Column).
      56:9   
NOTE: Invalid numeric data, '  Tuesday' , at Zeile 56 Spalte 9.
date1=15JAN2019 ID=1 NameDay=. _ERROR_=1 _N_=1
&lt;/PRE&gt;</description>
    <pubDate>Tue, 21 Jan 2020 08:54:57 GMT</pubDate>
    <dc:creator>Kurt_Bremser</dc:creator>
    <dc:date>2020-01-21T08:54:57Z</dc:date>
    <item>
      <title>name of day</title>
      <link>https://communities.sas.com/t5/SAS-Programming/name-of-day/m-p/618795#M181569</link>
      <description>&lt;P&gt;Hello&lt;/P&gt;
&lt;P&gt;I want to create another column with name of date (character type).&lt;/P&gt;
&lt;P&gt;What is wrong with me code please?&lt;/P&gt;
&lt;P&gt;Why&amp;nbsp;&amp;nbsp;nameDay=put(date1,dowName.)&amp;nbsp; &amp;nbsp;is not working and I get null values?&lt;/P&gt;
&lt;P&gt;Also I want to ask how can i do&amp;nbsp; it in one step (without creating another data set&amp;nbsp;RawTbl2)&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;Data RawTbl;
informat date1 date9.;
format date1 date9.;
input ID  date1  NameDay;
cards;
1 '15Jan2019'd 10
2 '17Jan2019'd 20
3 '19Jan2019'd 30
4 '21Jan2019'd 40
5 '23Jan2019'd 50
6 '18Jan2019'd 60
7 '17Jan2019'd 70
8 '08Jan2019'd 80
9 '04Jan2019'd 90
;
Run;

data RawTbl2 ;
set RawTbl;
nameDay=put(date1,dowName.) ;
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 21 Jan 2020 08:47:57 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/name-of-day/m-p/618795#M181569</guid>
      <dc:creator>Ronein</dc:creator>
      <dc:date>2020-01-21T08:47:57Z</dc:date>
    </item>
    <item>
      <title>Re: name of day</title>
      <link>https://communities.sas.com/t5/SAS-Programming/name-of-day/m-p/618796#M181570</link>
      <description>&lt;P&gt;nameday is defined numeric in the first data step; trying to assign it a character value will result in missing values and the corresponding NOTEs in the log.&lt;/P&gt;
&lt;P&gt;Maxim 2: Read the Log:&lt;/P&gt;
&lt;PRE&gt;54         data RawTbl2 ;
55         set RawTbl;
56         nameDay=put(date1,dowName.) ;
57         run;
NOTE: Character values have been converted to numeric values at the places given by: (Line):(Column).
      56:9   
NOTE: Invalid numeric data, '  Tuesday' , at Zeile 56 Spalte 9.
date1=15JAN2019 ID=1 NameDay=. _ERROR_=1 _N_=1
&lt;/PRE&gt;</description>
      <pubDate>Tue, 21 Jan 2020 08:54:57 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/name-of-day/m-p/618796#M181570</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2020-01-21T08:54:57Z</dc:date>
    </item>
    <item>
      <title>Re: name of day</title>
      <link>https://communities.sas.com/t5/SAS-Programming/name-of-day/m-p/618797#M181571</link>
      <description>&lt;P&gt;You get missing values because you define NameDay as a numeric variable in your first data set. Then in your second, you try to create a character variable with the same name.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;As for your second question, the answer is yes&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;Data RawTbl;
informat date1 date9.;
format date1 date9.;
input ID date1;
NameDay = put(date1,dowName. -l) ;
cards;
1 '15Jan2019'd
2 '17Jan2019'd
3 '19Jan2019'd
4 '21Jan2019'd
5 '23Jan2019'd
6 '18Jan2019'd
7 '17Jan2019'd
8 '08Jan2019'd
9 '04Jan2019'd
;
Run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 21 Jan 2020 08:55:08 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/name-of-day/m-p/618797#M181571</guid>
      <dc:creator>PeterClemmensen</dc:creator>
      <dc:date>2020-01-21T08:55:08Z</dc:date>
    </item>
  </channel>
</rss>

