<?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: How to get long strings as input in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/How-to-get-long-strings-as-input/m-p/83817#M18102</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I guess after a couple of days with no responses we can consider this closed.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you all - I learned something useful from each of your answers, and will absolutely try them all out.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please don't be offended - I was going to mark you all "Correct Answer", but I've never awarded these before and just discovered that there are limits on numbers - statistically, I consider this a poor practice&amp;nbsp;&amp;nbsp; &lt;span class="lia-unicode-emoji" title=":winking_face:"&gt;😉&lt;/span&gt;&lt;/P&gt;&lt;P&gt;So Art gets the green star for being first (and maybe for being a fellow Canuck?)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Happy Thanksgiving and Columbus Day to all of you!&lt;/P&gt;&lt;P&gt;&amp;nbsp; Tom&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 05 Oct 2012 22:02:38 GMT</pubDate>
    <dc:creator>TomKari</dc:creator>
    <dc:date>2012-10-05T22:02:38Z</dc:date>
    <item>
      <title>How to get long strings as input</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-get-long-strings-as-input/m-p/83813#M18098</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I'm having so much fun! I should have quit working years ago!!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Anyway, I've encountered situations in the past where I just want to grab the rows of an input file "in bulk", and do things to them using DATA step code. For years, I've been using the following code:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data work.test_data;&lt;BR /&gt;infile "C:\some_file.txt" lrecl=32767;&lt;BR /&gt;length inrec $ 32767;&lt;BR /&gt;input;&lt;BR /&gt;inrec = _infile_;&lt;/P&gt;&lt;P&gt;/* and then use inrec as my source of text for further processing, using string functions or PRX functions or whatever */&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I like it because I consider it the bare minimum, but would any changes improve it? Are there any conditions under which it won't work?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;&amp;nbsp; Tom&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Oct 2012 23:12:31 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-get-long-strings-as-input/m-p/83813#M18098</guid>
      <dc:creator>TomKari</dc:creator>
      <dc:date>2012-10-02T23:12:31Z</dc:date>
    </item>
    <item>
      <title>Re: How to get long strings as input</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-get-long-strings-as-input/m-p/83814#M18099</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Tom,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My personal preference, in such cases, is to use input @, modify _infile_ as needed, and then just use a normal input statement to re-read the modified data row.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Oct 2012 23:43:00 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-get-long-strings-as-input/m-p/83814#M18099</guid>
      <dc:creator>art297</dc:creator>
      <dc:date>2012-10-02T23:43:00Z</dc:date>
    </item>
    <item>
      <title>Re: How to get long strings as input</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-get-long-strings-as-input/m-p/83815#M18100</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;NO. Your code looks good. Here is an instead way.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data work.test_data;&lt;/P&gt;&lt;P&gt;infile "C:\some_file.txt"&amp;nbsp; length=len lrecl=32767;&lt;/P&gt;&lt;P&gt;input inrec $varying32676. len;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 03 Oct 2012 03:24:18 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-get-long-strings-as-input/m-p/83815#M18100</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2012-10-03T03:24:18Z</dc:date>
    </item>
    <item>
      <title>Re: How to get long strings as input</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-get-long-strings-as-input/m-p/83816#M18101</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Working with the RAW input record is perfectly OK and reasonable from my understanding,&lt;/P&gt;&lt;P&gt;but why not just use the automatic _infile_ variable and work from there?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I really don't see no need to copy it's content to a second variable, a 32K PDV is quite big in memory.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Cheers from Portugal.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Daniel Santos @ &lt;A href="http://www.cgd.pt" target="_blank"&gt;www.cgd.pt&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 03 Oct 2012 09:25:20 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-get-long-strings-as-input/m-p/83816#M18101</guid>
      <dc:creator>DanielSantos</dc:creator>
      <dc:date>2012-10-03T09:25:20Z</dc:date>
    </item>
    <item>
      <title>Re: How to get long strings as input</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-get-long-strings-as-input/m-p/83817#M18102</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I guess after a couple of days with no responses we can consider this closed.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you all - I learned something useful from each of your answers, and will absolutely try them all out.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please don't be offended - I was going to mark you all "Correct Answer", but I've never awarded these before and just discovered that there are limits on numbers - statistically, I consider this a poor practice&amp;nbsp;&amp;nbsp; &lt;span class="lia-unicode-emoji" title=":winking_face:"&gt;😉&lt;/span&gt;&lt;/P&gt;&lt;P&gt;So Art gets the green star for being first (and maybe for being a fellow Canuck?)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Happy Thanksgiving and Columbus Day to all of you!&lt;/P&gt;&lt;P&gt;&amp;nbsp; Tom&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 05 Oct 2012 22:02:38 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-get-long-strings-as-input/m-p/83817#M18102</guid>
      <dc:creator>TomKari</dc:creator>
      <dc:date>2012-10-05T22:02:38Z</dc:date>
    </item>
  </channel>
</rss>

