<?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 Reading specific field from .csv file in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Reading-specific-field-from-csv-file/m-p/62121#M13527</link>
    <description>Is there a way to read in one specific field from a .csv file?  I have a file that is compressed with gzip so I have to use a standard datastep to access it.  I can't use proc import.  There are several hundred fields and I only need fields 137 - 142.</description>
    <pubDate>Thu, 13 Jan 2011 15:56:39 GMT</pubDate>
    <dc:creator>Zelazny7</dc:creator>
    <dc:date>2011-01-13T15:56:39Z</dc:date>
    <item>
      <title>Reading specific field from .csv file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Reading-specific-field-from-csv-file/m-p/62121#M13527</link>
      <description>Is there a way to read in one specific field from a .csv file?  I have a file that is compressed with gzip so I have to use a standard datastep to access it.  I can't use proc import.  There are several hundred fields and I only need fields 137 - 142.</description>
      <pubDate>Thu, 13 Jan 2011 15:56:39 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Reading-specific-field-from-csv-file/m-p/62121#M13527</guid>
      <dc:creator>Zelazny7</dc:creator>
      <dc:date>2011-01-13T15:56:39Z</dc:date>
    </item>
    <item>
      <title>Re: Reading specific field from .csv file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Reading-specific-field-from-csv-file/m-p/62122#M13528</link>
      <description>Yes, you can use a data step similar to this one.&lt;BR /&gt;
&lt;BR /&gt;
[pre]&lt;BR /&gt;
data skip4fields;&lt;BR /&gt;
   infile cards dsd;&lt;BR /&gt;
   input (4*d)(:$1.) f5 f6;&lt;BR /&gt;
   drop d;&lt;BR /&gt;
   cards;&lt;BR /&gt;
1,2,3,4,5,6,7&lt;BR /&gt;
1,2,3,4,5,6,7&lt;BR /&gt;
;;;;&lt;BR /&gt;
   run;&lt;BR /&gt;
proc print;&lt;BR /&gt;
   run;&lt;BR /&gt;
[/pre]</description>
      <pubDate>Thu, 13 Jan 2011 16:18:48 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Reading-specific-field-from-csv-file/m-p/62122#M13528</guid>
      <dc:creator>data_null__</dc:creator>
      <dc:date>2011-01-13T16:18:48Z</dc:date>
    </item>
    <item>
      <title>Re: Reading specific field from .csv file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Reading-specific-field-from-csv-file/m-p/62123#M13529</link>
      <description>Very elegant solution, thank you!</description>
      <pubDate>Thu, 13 Jan 2011 16:53:38 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Reading-specific-field-from-csv-file/m-p/62123#M13529</guid>
      <dc:creator>Zelazny7</dc:creator>
      <dc:date>2011-01-13T16:53:38Z</dc:date>
    </item>
  </channel>
</rss>

