<?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: A Question Regarding Data Management in SAS Procedures</title>
    <link>https://communities.sas.com/t5/SAS-Procedures/A-Question-Regarding-Data-Management/m-p/40416#M10450</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks for all your help!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am new to SAS and I wonder if I can ask you another question about proc content? I am trying to ask SAS to list the variables with descriptions in a dataset but SAS keeps showing the variables in alphabetical orders. Is it possible to ask SAS to list the variables in the order they are in the dataset? &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The syntax that I used is as follow:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;proc content data=work.datafile;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you very much again!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Chester&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 02 Aug 2011 17:58:27 GMT</pubDate>
    <dc:creator>PsycResearcher</dc:creator>
    <dc:date>2011-08-02T17:58:27Z</dc:date>
    <item>
      <title>A Question Regarding Data Management</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/A-Question-Regarding-Data-Management/m-p/40413#M10447</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a question about data management in SAS, and I wonder if anyone can help me.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have an extremely large dataset. One column of the data represents data entered before the year 2005. Another column of data represents data entered after the year 2005. It looks like following:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE border="1" cellpadding="3" cellspacing="0" class="jiveBorder" style="width: 100%; border: 1px solid #000000;"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TH align="center" style="background-color: #6690bc;" valign="middle"&gt;&lt;SPAN style="color: #ffffff;"&gt;&lt;STRONG&gt;ColumnA&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/TH&gt;&lt;TH align="center" style="background-color: #6690bc;" valign="middle"&gt;&lt;SPAN style="color: #ffffff;"&gt;&lt;STRONG&gt;ColumnB&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/TH&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;.&lt;/TD&gt;&lt;TD&gt;7&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;.&lt;/TD&gt;&lt;TD&gt;9&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;.&lt;/TD&gt;&lt;TD&gt;6&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;.&lt;/TD&gt;&lt;TD&gt;5&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;.&lt;/TD&gt;&lt;TD&gt;3&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;3&lt;/TD&gt;&lt;TD&gt;.&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;4&lt;/TD&gt;&lt;TD&gt;.&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;5&lt;/TD&gt;&lt;TD&gt;.&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;8&lt;/TD&gt;&lt;TD&gt;.&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;( . represents missing data)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If I want to combine two columns into one (let's name it columnC, is there a way to do so in SAS?)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you very much for your help!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Chester&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Aug 2011 13:21:30 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/A-Question-Regarding-Data-Management/m-p/40413#M10447</guid>
      <dc:creator>PsycResearcher</dc:creator>
      <dc:date>2011-08-02T13:21:30Z</dc:date>
    </item>
    <item>
      <title>A Question Regarding Data Management</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/A-Question-Regarding-Data-Management/m-p/40414#M10448</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If the missing values are irrelevant, you might be able to use something like:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data have;&lt;/P&gt;&lt;P&gt;&amp;nbsp; input columna columnb;&lt;/P&gt;&lt;P&gt;&amp;nbsp; cards;&lt;/P&gt;&lt;P&gt;. 7&lt;/P&gt;&lt;P&gt;. 9&lt;/P&gt;&lt;P&gt;. 6&lt;/P&gt;&lt;P&gt;. 5&lt;/P&gt;&lt;P&gt;. 3&lt;/P&gt;&lt;P&gt;3 .&lt;/P&gt;&lt;P&gt;4 .&lt;/P&gt;&lt;P&gt;5 .&lt;/P&gt;&lt;P&gt;8 .&lt;/P&gt;&lt;P&gt;;&lt;/P&gt;&lt;P&gt;data want;&lt;/P&gt;&lt;P&gt;&amp;nbsp; set have (keep=columnb rename=(columnb=columnc)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; where=(not missing(columnc)))&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; have (keep=columna rename=(columna=columnc)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; where=(not missing(columnc)));&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Aug 2011 13:51:15 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/A-Question-Regarding-Data-Management/m-p/40414#M10448</guid>
      <dc:creator>art297</dc:creator>
      <dc:date>2011-08-02T13:51:15Z</dc:date>
    </item>
    <item>
      <title>Re: A Question Regarding Data Management</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/A-Question-Regarding-Data-Management/m-p/40415#M10449</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi ... another idea ...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: 'courier new', courier;"&gt;data have;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: 'courier new', courier;"&gt;input columna columnb;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: 'courier new', courier;"&gt;cards;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: 'courier new', courier;"&gt;. 7&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: 'courier new', courier;"&gt;. 9&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: 'courier new', courier;"&gt;. 6&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: 'courier new', courier;"&gt;. 5&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: 'courier new', courier;"&gt;. 3&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: 'courier new', courier;"&gt;3 .&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: 'courier new', courier;"&gt;4 .&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: 'courier new', courier;"&gt;5 .&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: 'courier new', courier;"&gt;8 .&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: 'courier new', courier;"&gt;;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: 'courier new', courier;"&gt;run;&lt;BR /&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: 'courier new', courier;"&gt;data want;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: 'courier new', courier;"&gt;set have;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: 'courier new', courier;"&gt;columnc = coalesce(of col:) ;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: 'courier new', courier;"&gt;keep columnc;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: 'courier new', courier;"&gt;run;&lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Aug 2011 17:43:28 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/A-Question-Regarding-Data-Management/m-p/40415#M10449</guid>
      <dc:creator>MikeZdeb</dc:creator>
      <dc:date>2011-08-02T17:43:28Z</dc:date>
    </item>
    <item>
      <title>Re: A Question Regarding Data Management</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/A-Question-Regarding-Data-Management/m-p/40416#M10450</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks for all your help!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am new to SAS and I wonder if I can ask you another question about proc content? I am trying to ask SAS to list the variables with descriptions in a dataset but SAS keeps showing the variables in alphabetical orders. Is it possible to ask SAS to list the variables in the order they are in the dataset? &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The syntax that I used is as follow:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;proc content data=work.datafile;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you very much again!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Chester&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Aug 2011 17:58:27 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/A-Question-Regarding-Data-Management/m-p/40416#M10450</guid>
      <dc:creator>PsycResearcher</dc:creator>
      <dc:date>2011-08-02T17:58:27Z</dc:date>
    </item>
    <item>
      <title>A Question Regarding Data Management</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/A-Question-Regarding-Data-Management/m-p/40417#M10451</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; Had read somewhere that in proc contents the VARNUM variable give you the position of the variable. Cannot confirm this right now so please check it once.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Aug 2011 18:40:47 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/A-Question-Regarding-Data-Management/m-p/40417#M10451</guid>
      <dc:creator>NN</dc:creator>
      <dc:date>2011-08-02T18:40:47Z</dc:date>
    </item>
    <item>
      <title>Re: A Question Regarding Data Management</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/A-Question-Regarding-Data-Management/m-p/40418#M10452</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I think you want the order=varnum option.&amp;nbsp; The options are described in the following link:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://support.sas.com/community/newsletters/news/techtips/OrderOption.html"&gt;http://support.sas.com/community/newsletters/news/techtips/OrderOption.html&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Aug 2011 18:41:13 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/A-Question-Regarding-Data-Management/m-p/40418#M10452</guid>
      <dc:creator>art297</dc:creator>
      <dc:date>2011-08-02T18:41:13Z</dc:date>
    </item>
    <item>
      <title>A Question Regarding Data Management</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/A-Question-Regarding-Data-Management/m-p/40419#M10453</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; VARNUM option provides the "logical" order&lt;/P&gt;&lt;P&gt;The internal storage order will often be different&lt;/P&gt;&lt;P&gt;The "logical" order is the order in which the variables are "discovered" by the compiler&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Aug 2011 22:37:40 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/A-Question-Regarding-Data-Management/m-p/40419#M10453</guid>
      <dc:creator>Peter_C</dc:creator>
      <dc:date>2011-08-02T22:37:40Z</dc:date>
    </item>
    <item>
      <title>A Question Regarding Data Management</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/A-Question-Regarding-Data-Management/m-p/40420#M10454</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks for being helpful!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Chester&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 03 Aug 2011 14:42:55 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/A-Question-Regarding-Data-Management/m-p/40420#M10454</guid>
      <dc:creator>PsycResearcher</dc:creator>
      <dc:date>2011-08-03T14:42:55Z</dc:date>
    </item>
  </channel>
</rss>

