<?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: ERROR: Expression using addition (+) requires numeric types. in SAS Procedures</title>
    <link>https://communities.sas.com/t5/SAS-Procedures/ERROR-Expression-using-addition-requires-numeric-types/m-p/200669#M50097</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;%let topfile=%eval(&amp;amp;topfile. +1)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;If your files all have the same structure and are in the same folder you can use something like the following instead:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;&lt;A __default_attr="10426" __jive_macro_name="document" class="jive_macro jive_macro_document" href="https://communities.sas.com/"&gt;&lt;/A&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sat, 11 Jul 2015 21:18:46 GMT</pubDate>
    <dc:creator>Reeza</dc:creator>
    <dc:date>2015-07-11T21:18:46Z</dc:date>
    <item>
      <title>ERROR: Expression using addition (+) requires numeric types.</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/ERROR-Expression-using-addition-requires-numeric-types/m-p/200667#M50095</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I am trying to read large number of files. Here i am using this variable topfile to add values everytime a file is read and add it as a column in my final dataset.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;%if %sysfunc(exist(mv.movers_signals_all))= 0 %then %do;&lt;/P&gt;&lt;P&gt;/*%local topfile; */&lt;/P&gt;&lt;P&gt;%let %topfile=1;&lt;/P&gt;&lt;P&gt;%end;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;%else %do;&lt;/P&gt;&lt;P&gt;%let topfile=%eval(&amp;amp;topfile+1)&lt;/P&gt;&lt;P&gt;proc sql;&lt;/P&gt;&lt;P&gt;select max(topfile)&amp;nbsp; into :topfile&lt;/P&gt;&lt;P&gt;from mv.movers_signals_all;&lt;/P&gt;&lt;P&gt;quit;&lt;/P&gt;&lt;P&gt;%end;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;%put &amp;amp;topfile;&lt;/P&gt;&lt;P&gt;proc sql;&lt;/P&gt;&lt;P&gt;create table mv.moversdata2_&amp;amp;filen. as&lt;/P&gt;&lt;P&gt;select "&amp;amp;filen" as filedate, "%topfile" as topfile,*&lt;/P&gt;&lt;P&gt;from mv.moversdata_&amp;amp;filen.;&lt;/P&gt;&lt;P&gt;quit;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am trying to read large number of files. Each file has about 50k observations. I want to differentiate between files and Here i am using this variable "topfile" to add values everytime a file is read and add it as a column in my final dataset. But while trying to add values in that macro variable, i am getting this error.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ERROR: Expression using addition (+ ) requires numeric types.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Jul 2015 20:11:18 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/ERROR-Expression-using-addition-requires-numeric-types/m-p/200667#M50095</guid>
      <dc:creator>mrajendranvasanthi</dc:creator>
      <dc:date>2015-07-11T20:11:18Z</dc:date>
    </item>
    <item>
      <title>Re: ERROR: Expression using addition (+) requires numeric types.</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/ERROR-Expression-using-addition-requires-numeric-types/m-p/200668#M50096</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Make sure you know when to use &amp;amp; and % in macro expressions. I see two syntax errors. They should be: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-size: 13px; background-color: #ffffff; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;%let topfile=1;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px; background-color: #ffffff;"&gt;and&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style=": ; font-size: 13px; background-color: #ffffff; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;select "&amp;amp;filen" as filedate, "&amp;amp;topfile" as topfile,*&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13px; background-color: #ffffff; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px; background-color: #ffffff;"&gt;PG&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Jul 2015 20:28:55 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/ERROR-Expression-using-addition-requires-numeric-types/m-p/200668#M50096</guid>
      <dc:creator>PGStats</dc:creator>
      <dc:date>2015-07-11T20:28:55Z</dc:date>
    </item>
    <item>
      <title>Re: ERROR: Expression using addition (+) requires numeric types.</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/ERROR-Expression-using-addition-requires-numeric-types/m-p/200669#M50097</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;%let topfile=%eval(&amp;amp;topfile. +1)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;If your files all have the same structure and are in the same folder you can use something like the following instead:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;&lt;A __default_attr="10426" __jive_macro_name="document" class="jive_macro jive_macro_document" href="https://communities.sas.com/"&gt;&lt;/A&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Jul 2015 21:18:46 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/ERROR-Expression-using-addition-requires-numeric-types/m-p/200669#M50097</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2015-07-11T21:18:46Z</dc:date>
    </item>
  </channel>
</rss>

