<?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: move a column to be the first one in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/move-a-column-to-be-the-first-one/m-p/66718#M14483</link>
    <description>length  or format statement works also.</description>
    <pubDate>Wed, 18 May 2011 18:37:08 GMT</pubDate>
    <dc:creator>SUN59338</dc:creator>
    <dc:date>2011-05-18T18:37:08Z</dc:date>
    <item>
      <title>move a column to be the first one</title>
      <link>https://communities.sas.com/t5/SAS-Programming/move-a-column-to-be-the-first-one/m-p/66714#M14479</link>
      <description>This is usually how I did when I want to move a column to be the first column in the dataset:&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
data a2;&lt;BR /&gt;
  retain idx;&lt;BR /&gt;
  set a1;&lt;BR /&gt;
  idx = _n_;&lt;BR /&gt;
run;&lt;BR /&gt;
&lt;BR /&gt;
Is there any better way to do this in data steps?</description>
      <pubDate>Tue, 17 May 2011 23:33:25 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/move-a-column-to-be-the-first-one/m-p/66714#M14479</guid>
      <dc:creator>MarcTC</dc:creator>
      <dc:date>2011-05-17T23:33:25Z</dc:date>
    </item>
    <item>
      <title>Re: move a column to be the first one</title>
      <link>https://communities.sas.com/t5/SAS-Programming/move-a-column-to-be-the-first-one/m-p/66715#M14480</link>
      <description>Then Should use this;&lt;BR /&gt;
[pre]&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
data temp;&lt;BR /&gt;
 idx=_n_;&lt;BR /&gt;
 set sashelp.class;&lt;BR /&gt;
run;&lt;BR /&gt;
[/pre]&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
Ksharp</description>
      <pubDate>Wed, 18 May 2011 10:25:35 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/move-a-column-to-be-the-first-one/m-p/66715#M14480</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2011-05-18T10:25:35Z</dc:date>
    </item>
    <item>
      <title>Re: move a column to be the first one</title>
      <link>https://communities.sas.com/t5/SAS-Programming/move-a-column-to-be-the-first-one/m-p/66716#M14481</link>
      <description>I'm glad you asked this because I've needed to do this and didn't know how!  Thanks!</description>
      <pubDate>Wed, 18 May 2011 16:39:16 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/move-a-column-to-be-the-first-one/m-p/66716#M14481</guid>
      <dc:creator>stateworker</dc:creator>
      <dc:date>2011-05-18T16:39:16Z</dc:date>
    </item>
    <item>
      <title>Re: move a column to be the first one</title>
      <link>https://communities.sas.com/t5/SAS-Programming/move-a-column-to-be-the-first-one/m-p/66717#M14482</link>
      <description>I'm glad you asked this because I've needed to do this and didn't know how!  Thanks!</description>
      <pubDate>Wed, 18 May 2011 16:41:07 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/move-a-column-to-be-the-first-one/m-p/66717#M14482</guid>
      <dc:creator>stateworker</dc:creator>
      <dc:date>2011-05-18T16:41:07Z</dc:date>
    </item>
    <item>
      <title>Re: move a column to be the first one</title>
      <link>https://communities.sas.com/t5/SAS-Programming/move-a-column-to-be-the-first-one/m-p/66718#M14483</link>
      <description>length  or format statement works also.</description>
      <pubDate>Wed, 18 May 2011 18:37:08 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/move-a-column-to-be-the-first-one/m-p/66718#M14483</guid>
      <dc:creator>SUN59338</dc:creator>
      <dc:date>2011-05-18T18:37:08Z</dc:date>
    </item>
  </channel>
</rss>

