<?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 Data type conversion in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Data-type-conversion/m-p/66600#M14465</link>
    <description>Hello everyone,&lt;BR /&gt;
&lt;BR /&gt;
I have been trying to figure this out for the second day now, and decided to find out if anyone here knows a way. &lt;BR /&gt;
&lt;BR /&gt;
The task I need to accomplish is the following:&lt;BR /&gt;
&lt;BR /&gt;
I have a variable k='01JAN2008'd;&lt;BR /&gt;
In order to call several datasets which have the name in the following form: work....._01JAN2008, work....._07JAN2008, and so on, I was trying to convert k, k+7*d, to character in a single line of code. I was trying to do the following: &lt;BR /&gt;
&lt;BR /&gt;
%macro a;&lt;BR /&gt;
%do i=1 %to 3;&lt;BR /&gt;
%let dt=%put(%sysevalf(&amp;amp;k+7*&amp;amp;i), date9.);&lt;BR /&gt;
%end;&lt;BR /&gt;
%mend;&lt;BR /&gt;
%aa;&lt;BR /&gt;
&lt;BR /&gt;
, but have not been successfull. I would really appreciate if somebody could point out what am I doing wrong.&lt;BR /&gt;
&lt;BR /&gt;
Thanks,&lt;BR /&gt;
Dmitry</description>
    <pubDate>Thu, 18 Dec 2008 19:03:00 GMT</pubDate>
    <dc:creator>dmitrym</dc:creator>
    <dc:date>2008-12-18T19:03:00Z</dc:date>
    <item>
      <title>Data type conversion</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Data-type-conversion/m-p/66600#M14465</link>
      <description>Hello everyone,&lt;BR /&gt;
&lt;BR /&gt;
I have been trying to figure this out for the second day now, and decided to find out if anyone here knows a way. &lt;BR /&gt;
&lt;BR /&gt;
The task I need to accomplish is the following:&lt;BR /&gt;
&lt;BR /&gt;
I have a variable k='01JAN2008'd;&lt;BR /&gt;
In order to call several datasets which have the name in the following form: work....._01JAN2008, work....._07JAN2008, and so on, I was trying to convert k, k+7*d, to character in a single line of code. I was trying to do the following: &lt;BR /&gt;
&lt;BR /&gt;
%macro a;&lt;BR /&gt;
%do i=1 %to 3;&lt;BR /&gt;
%let dt=%put(%sysevalf(&amp;amp;k+7*&amp;amp;i), date9.);&lt;BR /&gt;
%end;&lt;BR /&gt;
%mend;&lt;BR /&gt;
%aa;&lt;BR /&gt;
&lt;BR /&gt;
, but have not been successfull. I would really appreciate if somebody could point out what am I doing wrong.&lt;BR /&gt;
&lt;BR /&gt;
Thanks,&lt;BR /&gt;
Dmitry</description>
      <pubDate>Thu, 18 Dec 2008 19:03:00 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Data-type-conversion/m-p/66600#M14465</guid>
      <dc:creator>dmitrym</dc:creator>
      <dc:date>2008-12-18T19:03:00Z</dc:date>
    </item>
    <item>
      <title>Re: Data type conversion</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Data-type-conversion/m-p/66601#M14466</link>
      <description>You will need to use the %SYSFUNC and also use PUTN (instead of %PUT) to resolve a "formatted" SAS date string.&lt;BR /&gt;
&lt;BR /&gt;
Scott Barry&lt;BR /&gt;
SBBWorks, Inc.</description>
      <pubDate>Thu, 18 Dec 2008 19:39:40 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Data-type-conversion/m-p/66601#M14466</guid>
      <dc:creator>sbb</dc:creator>
      <dc:date>2008-12-18T19:39:40Z</dc:date>
    </item>
    <item>
      <title>Re: Data type conversion</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Data-type-conversion/m-p/66602#M14467</link>
      <description>Thank you very much! Worked like a charm&lt;BR /&gt;
&lt;BR /&gt;
Dmitry</description>
      <pubDate>Thu, 18 Dec 2008 19:45:17 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Data-type-conversion/m-p/66602#M14467</guid>
      <dc:creator>dmitrym</dc:creator>
      <dc:date>2008-12-18T19:45:17Z</dc:date>
    </item>
  </channel>
</rss>

