<?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 Help with infile/input giving me an empty dataset in SAS Procedures</title>
    <link>https://communities.sas.com/t5/SAS-Procedures/Help-with-infile-input-giving-me-an-empty-dataset/m-p/21170#M4451</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The default looks like it's set up for a unix based system, or at least where "gunzip" is available (which you can get for Windows too).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I managed to get it to run by following your instructions, but changing the libname and filename statements as below (with the data file unzipped manually).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;libname&amp;nbsp; sasdata 'C:\temp\';&lt;/P&gt;&lt;P&gt;filename indata91 'C:\temp\dist91.dat';&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope that helps!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sun, 26 Jun 2011 23:38:20 GMT</pubDate>
    <dc:creator>DF</dc:creator>
    <dc:date>2011-06-26T23:38:20Z</dc:date>
    <item>
      <title>Help with infile/input giving me an empty dataset</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Help-with-infile-input-giving-me-an-empty-dataset/m-p/21169#M4450</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello all-&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am quite new to SAS (I actually learned the basics some years ago but have since not needed to use the software) and am having trouble running a program that was provided by another researcher to input and clean their dataset (both the programs and data are publicly available). I have tried to adapt the initial commands to direct to where I have put the datasets, but when I run the program I end up with a dataset which has all the variable names but is empty!! Below is the initial part of the code. My procees has been:&lt;/P&gt;&lt;P&gt;1) download the file dist91.data.gz from the source&lt;/P&gt;&lt;P&gt;2) place this file in C:\temp\ directory&lt;/P&gt;&lt;P&gt;3) Change the "libname "statement below to read : libname sasdata 'C:\temp';&lt;/P&gt;&lt;P&gt;4) hit "run"&lt;/P&gt;&lt;P&gt;5) end up with an empty dataset.&lt;/P&gt;&lt;P&gt;6) I have also tried the same as above and also unzipping the .gz file into its raw .dat format, and changing the filename statement to read: filename indata91&amp;nbsp; 'dist91.dat';&lt;/P&gt;&lt;P&gt;7) same thing happens. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;As far as I know, this code was written in 2003 and possibly not changed or debugged for newer releases of SAS? I am currently running SAS 9.1 on a Windows 7 based PC. I am probably missing some important syntax, or the code was written for UNIX? &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;The data and programs are downloadable here: &lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="http://www.bsos.umd.edu/socy/vanneman/districts/files/index.html"&gt;http://www.bsos.umd.edu/socy/vanneman/districts/files/index.html&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am in need to processing the 1991 data to support an academic research grant application, and can't even get this first piece done. Any thoughts or help most appreciated!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;_______________________________________Begin SAS code:&lt;/P&gt;&lt;P&gt;/* Users will need to create their own libname and filename commands&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; as appropriate for their local computer system&lt;/P&gt;&lt;P&gt;*/&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;libname&amp;nbsp; sasdata '.';&lt;/P&gt;&lt;P&gt;filename indata91&amp;nbsp; pipe 'gunzip -c dist91.data.gz';&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data sasdata.dist91 (label='Indian 1991 districts: from dist91.dat');&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; /* These temporary variables are used only to check &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; correct order of input data file */&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; drop rec140 rec160 rec300 rec340 rec620 rec650 rec670 rec690 ;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; attrib DLABEL length = $ 28;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;infile indata91 ;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;input&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; /*000*/&amp;nbsp; /* label record */&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; stateid&amp;nbsp; $ 1-2 &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; distid&amp;nbsp;&amp;nbsp; $ 3-4 &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; rec000&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 5-7&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; year&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 8-9&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; version&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 10&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; dlabel &amp;amp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; /* Total Population */&amp;nbsp; &lt;/P&gt;&lt;P&gt;/ /*100*/&amp;nbsp; pop&amp;nbsp; 11-19&amp;nbsp; rural 20-28&amp;nbsp; male&amp;nbsp; 29-37&amp;nbsp; Rmale&amp;nbsp; 38-46&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 26 Jun 2011 23:18:19 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Help-with-infile-input-giving-me-an-empty-dataset/m-p/21169#M4450</guid>
      <dc:creator>soconnell152</dc:creator>
      <dc:date>2011-06-26T23:18:19Z</dc:date>
    </item>
    <item>
      <title>Help with infile/input giving me an empty dataset</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Help-with-infile-input-giving-me-an-empty-dataset/m-p/21170#M4451</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The default looks like it's set up for a unix based system, or at least where "gunzip" is available (which you can get for Windows too).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I managed to get it to run by following your instructions, but changing the libname and filename statements as below (with the data file unzipped manually).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;libname&amp;nbsp; sasdata 'C:\temp\';&lt;/P&gt;&lt;P&gt;filename indata91 'C:\temp\dist91.dat';&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope that helps!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 26 Jun 2011 23:38:20 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Help-with-infile-input-giving-me-an-empty-dataset/m-p/21170#M4451</guid>
      <dc:creator>DF</dc:creator>
      <dc:date>2011-06-26T23:38:20Z</dc:date>
    </item>
  </channel>
</rss>

