<?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: Usage of &amp;quot;+&amp;quot; symbol in input/put statement ? in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Usage-of-quot-quot-symbol-in-input-put-statement/m-p/320109#M70448</link>
    <description>&lt;P&gt;Thank you, I tried the below code. I have understood the use of "+" symbol here, but in the output I am only getting one record which is for Henri. Why is that so?&lt;/P&gt;</description>
    <pubDate>Tue, 20 Dec 2016 06:48:29 GMT</pubDate>
    <dc:creator>PoojaP1</dc:creator>
    <dc:date>2016-12-20T06:48:29Z</dc:date>
    <item>
      <title>Usage of "+" symbol in input/put statement ?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Usage-of-quot-quot-symbol-in-input-put-statement/m-p/320105#M70445</link>
      <description>&lt;P&gt;&lt;SPAN&gt;The contents of the raw data file TEAM are listed below:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;--------10-------20-------30&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Janice 10&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Henri 11&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Michael 11&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Susan 12&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The following SAS program is submitted:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;data group;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;infile 'team';&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;input name $15. age 2.;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;file 'file-specification';&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;put name $15. +5 age 2.;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;run;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Which one of the following describes the output created?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;A. a raw data file only&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;B. a SAS data set named GROUP only&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;C. a SAS data set named GROUP and a raw data file&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;D. No output is generated as the program fails to execute due to errors.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I am not able to get a clear picture of how "+" pointer is working here. Could anyone please explain this ?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Thank you!&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 20 Dec 2016 06:23:07 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Usage-of-quot-quot-symbol-in-input-put-statement/m-p/320105#M70445</guid>
      <dc:creator>PoojaP1</dc:creator>
      <dc:date>2016-12-20T06:23:07Z</dc:date>
    </item>
    <item>
      <title>Re: Usage of "+" symbol in input/put statement ?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Usage-of-quot-quot-symbol-in-input-put-statement/m-p/320107#M70447</link>
      <description>&lt;P&gt;+5 would add 5 spaces after printing name variable. As name itself is 15 char long so age would be printed after 15 characters.&lt;/P&gt;&lt;P&gt;You can try giving +50 insted of+5 and see the log you would understand the usage. Try the below program.&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data group;
/* infile 'team'; */
input name $15. age 2.;
/* file 'file-specification'; */
 put name $15.  +5 age 2.; 
datalines;
Janice         10
Henri          11
Michael        11
Susan          12
;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 20 Dec 2016 06:35:21 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Usage-of-quot-quot-symbol-in-input-put-statement/m-p/320107#M70447</guid>
      <dc:creator>RahulG</dc:creator>
      <dc:date>2016-12-20T06:35:21Z</dc:date>
    </item>
    <item>
      <title>Re: Usage of "+" symbol in input/put statement ?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Usage-of-quot-quot-symbol-in-input-put-statement/m-p/320109#M70448</link>
      <description>&lt;P&gt;Thank you, I tried the below code. I have understood the use of "+" symbol here, but in the output I am only getting one record which is for Henri. Why is that so?&lt;/P&gt;</description>
      <pubDate>Tue, 20 Dec 2016 06:48:29 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Usage-of-quot-quot-symbol-in-input-put-statement/m-p/320109#M70448</guid>
      <dc:creator>PoojaP1</dc:creator>
      <dc:date>2016-12-20T06:48:29Z</dc:date>
    </item>
    <item>
      <title>Re: Usage of "+" symbol in input/put statement ?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Usage-of-quot-quot-symbol-in-input-put-statement/m-p/320114#M70451</link>
      <description>&lt;P&gt;Above code is working fine. Try to see if you are missing something otherwise share your log.&lt;/P&gt;</description>
      <pubDate>Tue, 20 Dec 2016 07:22:55 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Usage-of-quot-quot-symbol-in-input-put-statement/m-p/320114#M70451</guid>
      <dc:creator>RahulG</dc:creator>
      <dc:date>2016-12-20T07:22:55Z</dc:date>
    </item>
    <item>
      <title>Re: Usage of "+" symbol in input/put statement ?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Usage-of-quot-quot-symbol-in-input-put-statement/m-p/320289#M70513</link>
      <description>&lt;P&gt;Look in your log. Do you see any messages about SAS went to the next line?&lt;/P&gt;
&lt;P&gt;You may be requesting to read more data than exists on a single line.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Also when asking why something happened it often helps to post the code from the log along with any messages.&lt;/P&gt;</description>
      <pubDate>Tue, 20 Dec 2016 15:49:51 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Usage-of-quot-quot-symbol-in-input-put-statement/m-p/320289#M70513</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2016-12-20T15:49:51Z</dc:date>
    </item>
  </channel>
</rss>

