<?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: Strange result in data step in SAS Procedures</title>
    <link>https://communities.sas.com/t5/SAS-Procedures/Strange-result-in-data-step/m-p/66890#M19114</link>
    <description>Check the catx syntax&lt;BR /&gt;
&lt;BR /&gt;
CATX(separator, string-1 &amp;lt;, ...string-n&amp;gt;) &lt;BR /&gt;
&lt;BR /&gt;
01 is being used as the separator for the other two strings.</description>
    <pubDate>Fri, 28 Jan 2011 20:40:52 GMT</pubDate>
    <dc:creator>RickM</dc:creator>
    <dc:date>2011-01-28T20:40:52Z</dc:date>
    <item>
      <title>Strange result in data step</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Strange-result-in-data-step/m-p/66889#M19113</link>
      <description>Have I lost my mind or is somethin wrong here?&lt;BR /&gt;
&lt;BR /&gt;
data _null_;&lt;BR /&gt;
cur_yr    = year(today());                               &lt;BR /&gt;
cur_day   = day(today());&lt;BR /&gt;
cur_mnth  = month(today());&lt;BR /&gt;
x= catx(put(cur_mnth, z2.), put(cur_day, z2.), put(cur_yr, z4.)); &lt;BR /&gt;
y = compress(put(cur_mnth, z2.)|| put(cur_day, z2.) || put(cur_yr, z4.));&lt;BR /&gt;
put 'HERE  ' cur_mnth cur_day cur_yr ;&lt;BR /&gt;
put x=;&lt;BR /&gt;
put y=;&lt;BR /&gt;
      call symput('rundat8', catx(put(cur_mnth, z2.), put(cur_day, z2.), put(cur_yr, z4.)));&lt;BR /&gt;
run;&lt;BR /&gt;
%put &amp;amp;rundat8 ;&lt;BR /&gt;
&lt;BR /&gt;
Results in &lt;BR /&gt;
HERE  1 28 2011&lt;BR /&gt;
x=28012011&lt;BR /&gt;
y=01282011&lt;BR /&gt;
NOTE: DATA statement used (Total process time):&lt;BR /&gt;
      real time           0.05 seconds&lt;BR /&gt;
      cpu time            0.00 seconds&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
33   %put &amp;amp;rundat8 ;&lt;BR /&gt;
28012011&lt;BR /&gt;
&lt;BR /&gt;
How is the CATX reversing the order of the values?   &lt;BR /&gt;
Same result in 9.1 on Unix and 9.2 on WIN 7</description>
      <pubDate>Fri, 28 Jan 2011 20:32:09 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Strange-result-in-data-step/m-p/66889#M19113</guid>
      <dc:creator>Flip</dc:creator>
      <dc:date>2011-01-28T20:32:09Z</dc:date>
    </item>
    <item>
      <title>Re: Strange result in data step</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Strange-result-in-data-step/m-p/66890#M19114</link>
      <description>Check the catx syntax&lt;BR /&gt;
&lt;BR /&gt;
CATX(separator, string-1 &amp;lt;, ...string-n&amp;gt;) &lt;BR /&gt;
&lt;BR /&gt;
01 is being used as the separator for the other two strings.</description>
      <pubDate>Fri, 28 Jan 2011 20:40:52 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Strange-result-in-data-step/m-p/66890#M19114</guid>
      <dc:creator>RickM</dc:creator>
      <dc:date>2011-01-28T20:40:52Z</dc:date>
    </item>
    <item>
      <title>Re: Strange result in data step</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Strange-result-in-data-step/m-p/66891#M19115</link>
      <description>Thanks, I knew it had to be a Friday afternoon brain death.</description>
      <pubDate>Fri, 28 Jan 2011 20:46:20 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Strange-result-in-data-step/m-p/66891#M19115</guid>
      <dc:creator>Flip</dc:creator>
      <dc:date>2011-01-28T20:46:20Z</dc:date>
    </item>
  </channel>
</rss>

