<?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: changing place for variable from one place to another place in SAS Enterprise Guide</title>
    <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/changing-place-for-variable-from-one-place-to-another-place/m-p/84820#M8124</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Just add an ATTRIB statement before you read your dataset to make it first:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data new;&lt;/P&gt;&lt;P&gt;&amp;nbsp; attrib empsal length = 8;&lt;/P&gt;&lt;P&gt;&amp;nbsp; set old;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;If you want it second then add the variable you want first before empsal in the ATTRIB statement.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 21 Mar 2013 19:05:59 GMT</pubDate>
    <dc:creator>SASKiwi</dc:creator>
    <dc:date>2013-03-21T19:05:59Z</dc:date>
    <item>
      <title>changing place for variable from one place to another place</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/changing-place-for-variable-from-one-place-to-another-place/m-p/84819#M8123</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi all, i have one variable name 'empsal' in middle of dataset (have around 9000 variable and 'empsal' is there in between) and i wants to bring it as second or first variable/column,- how can i do that?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;plz help&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanks.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 21 Mar 2013 15:51:31 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/changing-place-for-variable-from-one-place-to-another-place/m-p/84819#M8123</guid>
      <dc:creator>sas_9</dc:creator>
      <dc:date>2013-03-21T15:51:31Z</dc:date>
    </item>
    <item>
      <title>Re: changing place for variable from one place to another place</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/changing-place-for-variable-from-one-place-to-another-place/m-p/84820#M8124</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Just add an ATTRIB statement before you read your dataset to make it first:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data new;&lt;/P&gt;&lt;P&gt;&amp;nbsp; attrib empsal length = 8;&lt;/P&gt;&lt;P&gt;&amp;nbsp; set old;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;If you want it second then add the variable you want first before empsal in the ATTRIB statement.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 21 Mar 2013 19:05:59 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/changing-place-for-variable-from-one-place-to-another-place/m-p/84820#M8124</guid>
      <dc:creator>SASKiwi</dc:creator>
      <dc:date>2013-03-21T19:05:59Z</dc:date>
    </item>
    <item>
      <title>Re: changing place for variable from one place to another place</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/changing-place-for-variable-from-one-place-to-another-place/m-p/84821#M8125</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;worked prefectly - Thanks SASKIWI.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;one quick q, i have 'empsal' variable as employee name and salary,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;e,g;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;empsal&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;harstein1 150000&lt;/P&gt;&lt;P&gt;lawson2 120000&lt;/P&gt;&lt;P&gt;kumar3 50000&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i want to keep salary only (150000, 120000, 50000) and remove (harstein1, lawson2, kumar3).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;result would be;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;empsal&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;150000&lt;/P&gt;&lt;P&gt;120000&lt;/P&gt;&lt;P&gt;50000&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;can you plz tell me how code should look like?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 21 Mar 2013 19:26:57 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/changing-place-for-variable-from-one-place-to-another-place/m-p/84821#M8125</guid>
      <dc:creator>sas_9</dc:creator>
      <dc:date>2013-03-21T19:26:57Z</dc:date>
    </item>
    <item>
      <title>Re: changing place for variable from one place to another place</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/changing-place-for-variable-from-one-place-to-another-place/m-p/84822#M8126</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If it's consistently always two words then you could do it this way:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;empsal = scan(empsal,2);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;However wouldn't it be better to store empsal as a number:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;empsal_num = input(scan(empsal,2), best12.);&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 22 Mar 2013 04:16:31 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/changing-place-for-variable-from-one-place-to-another-place/m-p/84822#M8126</guid>
      <dc:creator>SASKiwi</dc:creator>
      <dc:date>2013-03-22T04:16:31Z</dc:date>
    </item>
  </channel>
</rss>

