<?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: Importing multiple xlsx files with multiple xlsx sheets into SAS 9.4 in SAS Enterprise Guide</title>
    <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Importing-multiple-xlsx-files-with-multiple-xlsx-sheets-into-SAS/m-p/322373#M21554</link>
    <description>&lt;P&gt;I ran it. Got a list and 1 of the entries was:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;NOXCMD Disables the X command in SAS.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Wed, 04 Jan 2017 11:28:24 GMT</pubDate>
    <dc:creator>RensMeerman</dc:creator>
    <dc:date>2017-01-04T11:28:24Z</dc:date>
    <item>
      <title>Importing multiple xlsx files with multiple xlsx sheets into SAS 9.4</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Importing-multiple-xlsx-files-with-multiple-xlsx-sheets-into-SAS/m-p/322369#M21552</link>
      <description>&lt;P&gt;Dear community,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have the following code but it gives me an error that I do not know how to fix. Please advise.&lt;/P&gt;&lt;P&gt;&amp;nbsp;***************** CODE*********************&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;STRONG&gt;%macro&lt;/STRONG&gt;&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; impt(filename,i); &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;proc import DATAFILE=&lt;/FONT&gt;&lt;FONT color="#800080" face="Courier New" size="3"&gt;"&amp;amp;filename"&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; OUT=XL&amp;amp;i DBMS=XLSX REPLACE;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;%mend&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt; impt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;%let&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; path = E:\Lev1\Data\1_INPUTDOCS\IMPDOC\;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;STRONG&gt;data&lt;/STRONG&gt;&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;_null_&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;; &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;command = &lt;/FONT&gt;&lt;FONT color="#800080" face="Courier New" size="3"&gt;"dir &amp;amp;path.*.xlsx /b"&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;;; &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;infile&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;dummy&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;pipe&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;filevar&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;=command &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;end&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;=eof &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;truncover&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;; &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;do&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; i = &lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;1&lt;/FONT&gt;&lt;/STRONG&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;by&lt;/FONT&gt; &lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;1&lt;/FONT&gt;&lt;/STRONG&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;while&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;(not eof);&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;input&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; path &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;$128.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;; &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;path=catt(&lt;/FONT&gt;&lt;FONT color="#800080" face="Courier New" size="3"&gt;"&amp;amp;path."&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,path);&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;put&lt;/FONT&gt; &lt;FONT color="#800080" face="Courier New" size="3"&gt;'NOTE: '&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; path=;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;call&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; execute(cats(&lt;/FONT&gt;&lt;FONT color="#800080" face="Courier New" size="3"&gt;'%nrstr(%impt('&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,path,&lt;/FONT&gt;&lt;FONT color="#800080" face="Courier New" size="3"&gt;','&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,i,&lt;/FONT&gt;&lt;FONT color="#800080" face="Courier New" size="3"&gt;'));'&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;));&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;end&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;; &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;stop&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;; &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;run&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;; &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;STRONG&gt;data&lt;/STRONG&gt;&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; all;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;set&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; XL:;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;run&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;*********** ERROR LOG ******************&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;ERROR: Insufficient authorization to access PIPE.&lt;/P&gt;&lt;P&gt;command=dir E:\Lev1\Data\1_INPUTDOCS\IMPDOC\*.xlsx /b eof=0 i=. path= _ERROR_=1 _N_=1&lt;/P&gt;&lt;P&gt;NOTE: The SAS System stopped processing this step because of errors.&lt;/P&gt;&lt;P&gt;NOTE: DATA statement used (Total process time):&lt;/P&gt;&lt;P&gt;real time 0.03 seconds&lt;/P&gt;&lt;P&gt;cpu time 0.01 seconds&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;41&lt;/P&gt;&lt;P&gt;42 data all;&lt;/P&gt;&lt;P&gt;43 set XL:;&lt;/P&gt;&lt;P&gt;ERROR: The data set list (WORK.XL:) does not contain any members.&lt;/P&gt;&lt;P&gt;44 run;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 04 Jan 2017 11:12:28 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Importing-multiple-xlsx-files-with-multiple-xlsx-sheets-into-SAS/m-p/322369#M21552</guid>
      <dc:creator>RensMeerman</dc:creator>
      <dc:date>2017-01-04T11:12:28Z</dc:date>
    </item>
    <item>
      <title>Re: Importing multiple xlsx files with multiple xlsx sheets into SAS 9.4</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Importing-multiple-xlsx-files-with-multiple-xlsx-sheets-into-SAS/m-p/322372#M21553</link>
      <description>&lt;P&gt;Please run&amp;nbsp;&lt;SPAN&gt;PROC OPTIONS to verify that XCMD is set.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 04 Jan 2017 11:22:29 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Importing-multiple-xlsx-files-with-multiple-xlsx-sheets-into-SAS/m-p/322372#M21553</guid>
      <dc:creator>Kalind_Patel</dc:creator>
      <dc:date>2017-01-04T11:22:29Z</dc:date>
    </item>
    <item>
      <title>Re: Importing multiple xlsx files with multiple xlsx sheets into SAS 9.4</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Importing-multiple-xlsx-files-with-multiple-xlsx-sheets-into-SAS/m-p/322373#M21554</link>
      <description>&lt;P&gt;I ran it. Got a list and 1 of the entries was:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;NOXCMD Disables the X command in SAS.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 04 Jan 2017 11:28:24 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Importing-multiple-xlsx-files-with-multiple-xlsx-sheets-into-SAS/m-p/322373#M21554</guid>
      <dc:creator>RensMeerman</dc:creator>
      <dc:date>2017-01-04T11:28:24Z</dc:date>
    </item>
    <item>
      <title>Re: Importing multiple xlsx files with multiple xlsx sheets into SAS 9.4</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Importing-multiple-xlsx-files-with-multiple-xlsx-sheets-into-SAS/m-p/322377#M21555</link>
      <description>&lt;P&gt;Okay please enable XCMD option to use pipe command,&lt;/P&gt;&lt;P&gt;your SAS Admin might help you on this.&lt;/P&gt;&lt;P&gt;Refer this link, it will give you clear explanation why we have to enable XCMD option before using pipe command:&lt;/P&gt;&lt;P&gt;&lt;A href="http://support.sas.com/documentation/cdl/en/hostwin/69955/HTML/default/viewer.htm#p0xtd57b40ehdfn1jyk8yxemfrtv.htm" target="_blank"&gt;http://support.sas.com/documentation/cdl/en/hostwin/69955/HTML/default/viewer.htm#p0xtd57b40ehdfn1jyk8yxemfrtv.htm&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 04 Jan 2017 11:44:39 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Importing-multiple-xlsx-files-with-multiple-xlsx-sheets-into-SAS/m-p/322377#M21555</guid>
      <dc:creator>Kalind_Patel</dc:creator>
      <dc:date>2017-01-04T11:44:39Z</dc:date>
    </item>
    <item>
      <title>Re: Importing multiple xlsx files with multiple xlsx sheets into SAS 9.4</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Importing-multiple-xlsx-files-with-multiple-xlsx-sheets-into-SAS/m-p/322383#M21558</link>
      <description>&lt;P&gt;If you don't have permissions to change XCMD setting, which is highly likely, consider alternatives.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Theres a task that should list all files and see the directory traversal example here&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="http://www2.sas.com/proceedings/forum2007/008-2007.pdf" target="_blank"&gt;http://www2.sas.com/proceedings/forum2007/008-2007.pdf&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 04 Jan 2017 12:39:08 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Importing-multiple-xlsx-files-with-multiple-xlsx-sheets-into-SAS/m-p/322383#M21558</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2017-01-04T12:39:08Z</dc:date>
    </item>
  </channel>
</rss>

