<?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 read data in the following code in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/How-to-read-data-in-the-following-code/m-p/767327#M243268</link>
    <description>I tried but the log shows No DATALINES or INFILE statement.</description>
    <pubDate>Mon, 13 Sep 2021 06:25:38 GMT</pubDate>
    <dc:creator>shimengj</dc:creator>
    <dc:date>2021-09-13T06:25:38Z</dc:date>
    <item>
      <title>How to read data in the following code</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-read-data-in-the-following-code/m-p/767322#M243264</link>
      <description>&lt;P&gt;&amp;#8;I have a dataset 'wineA', here is the code I have to use, but I cannot read this dataset. I need some help with adding the code of reading 'wineA' into the following code.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;data wineA2;&lt;BR /&gt;input dummy $ @@;&lt;BR /&gt;length gender $ 1;&lt;BR /&gt;n_char = length(dummy);&lt;BR /&gt;gender = substr(dummy,n_char,1);&lt;BR /&gt;age = substr(dummy,1,n_char-1);&lt;BR /&gt;if last eq 'F' then Female=input(first,5.);&lt;BR /&gt;else if last eq 'M' then Male=input(first,5.);&lt;BR /&gt;run;&lt;BR /&gt;&lt;BR /&gt;proc print data=wineA2;&lt;BR /&gt;run;&lt;/P&gt;</description>
      <pubDate>Mon, 13 Sep 2021 06:01:13 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-read-data-in-the-following-code/m-p/767322#M243264</guid>
      <dc:creator>shimengj</dc:creator>
      <dc:date>2021-09-13T06:01:13Z</dc:date>
    </item>
    <item>
      <title>Re: How to read data in the following code</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-read-data-in-the-following-code/m-p/767324#M243265</link>
      <description>&lt;P&gt;Is WineA a SAS data set or an external data set like a txt/csv file ?&lt;/P&gt;</description>
      <pubDate>Mon, 13 Sep 2021 06:14:46 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-read-data-in-the-following-code/m-p/767324#M243265</guid>
      <dc:creator>PeterClemmensen</dc:creator>
      <dc:date>2021-09-13T06:14:46Z</dc:date>
    </item>
    <item>
      <title>Re: How to read data in the following code</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-read-data-in-the-following-code/m-p/767325#M243266</link>
      <description>just a dataset I created in my programming</description>
      <pubDate>Mon, 13 Sep 2021 06:18:20 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-read-data-in-the-following-code/m-p/767325#M243266</guid>
      <dc:creator>shimengj</dc:creator>
      <dc:date>2021-09-13T06:18:20Z</dc:date>
    </item>
    <item>
      <title>Re: How to read data in the following code</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-read-data-in-the-following-code/m-p/767326#M243267</link>
      <description>&lt;P&gt;The use a simple Set Statement? &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data wineA2;
set wine1;
/* More Code */;
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 13 Sep 2021 06:22:00 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-read-data-in-the-following-code/m-p/767326#M243267</guid>
      <dc:creator>PeterClemmensen</dc:creator>
      <dc:date>2021-09-13T06:22:00Z</dc:date>
    </item>
    <item>
      <title>Re: How to read data in the following code</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-read-data-in-the-following-code/m-p/767327#M243268</link>
      <description>I tried but the log shows No DATALINES or INFILE statement.</description>
      <pubDate>Mon, 13 Sep 2021 06:25:38 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-read-data-in-the-following-code/m-p/767327#M243268</guid>
      <dc:creator>shimengj</dc:creator>
      <dc:date>2021-09-13T06:25:38Z</dc:date>
    </item>
    <item>
      <title>Re: How to read data in the following code</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-read-data-in-the-following-code/m-p/767328#M243269</link>
      <description>&lt;P&gt;Drop this line and try again.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;input dummy $ @@;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 13 Sep 2021 06:28:26 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-read-data-in-the-following-code/m-p/767328#M243269</guid>
      <dc:creator>PeterClemmensen</dc:creator>
      <dc:date>2021-09-13T06:28:26Z</dc:date>
    </item>
    <item>
      <title>Re: How to read data in the following code</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-read-data-in-the-following-code/m-p/767330#M243270</link>
      <description>does not work... it comes out with a lot of empty variables like age, last. For this step, the question asks me to split variables made up with numbers and characters, ex 32F or 31M. So the final output should have individual variables gender and age.</description>
      <pubDate>Mon, 13 Sep 2021 06:33:03 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-read-data-in-the-following-code/m-p/767330#M243270</guid>
      <dc:creator>shimengj</dc:creator>
      <dc:date>2021-09-13T06:33:03Z</dc:date>
    </item>
    <item>
      <title>Re: How to read data in the following code</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-read-data-in-the-following-code/m-p/767366#M243278</link>
      <description>&lt;P&gt;Can you please post your code and sample data as a data step? (Use the running man icon above to open the code windows and place the code there.&lt;/P&gt;
&lt;P&gt;In addition do post your log showing the error.(Please click the &amp;lt;/&amp;gt; icon above and place the log in that window).&lt;/P&gt;</description>
      <pubDate>Mon, 13 Sep 2021 11:29:06 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-read-data-in-the-following-code/m-p/767366#M243278</guid>
      <dc:creator>Sajid01</dc:creator>
      <dc:date>2021-09-13T11:29:06Z</dc:date>
    </item>
    <item>
      <title>Re: How to read data in the following code</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-read-data-in-the-following-code/m-p/767416#M243294</link>
      <description>&lt;P&gt;While the advice&amp;nbsp; you have gotten so far contains a lot of good ideas, I think you need more specific guidance on what to do.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;To begin, while you say you created a data set wineA, notice that your program does not use wineA in any way.&amp;nbsp; To use it properly, you have to determine what is in wineA.&amp;nbsp; Is it a SAS data set, or a text file.&amp;nbsp; If it's a SAS data set, this program will run without error:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data test;
set wineA;
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;So let's start there and see what you get as the result.&amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;We will probably go through several steps before your question is resolved.&lt;/P&gt;</description>
      <pubDate>Mon, 13 Sep 2021 14:02:03 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-read-data-in-the-following-code/m-p/767416#M243294</guid>
      <dc:creator>Astounding</dc:creator>
      <dc:date>2021-09-13T14:02:03Z</dc:date>
    </item>
  </channel>
</rss>

