<?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 xls directly from Zip files in SAS Procedures</title>
    <link>https://communities.sas.com/t5/SAS-Procedures/Importing-xls-directly-from-Zip-files/m-p/155040#M40718</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Tom I m getting folowing error when trying on sas 9.2 version.&lt;/P&gt;&lt;P&gt;Does zip engine support 9.2 version?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; %let path=C:\Users\venkatnaveen\AppData\Local\Temp;&lt;/P&gt;&lt;P&gt;39&lt;/P&gt;&lt;P&gt;40&amp;nbsp;&amp;nbsp; %let basename=ads_vintages;&lt;/P&gt;&lt;P&gt;41&lt;/P&gt;&lt;P&gt;42&amp;nbsp;&amp;nbsp; %let ziploc=&amp;amp;path\&amp;amp;basename..zip ;&lt;/P&gt;&lt;P&gt;43&lt;/P&gt;&lt;P&gt;44&amp;nbsp;&amp;nbsp; %let xlsfile=&amp;amp;path\&amp;amp;basename..xls ;&lt;/P&gt;&lt;P&gt;45&lt;/P&gt;&lt;P&gt;46&amp;nbsp;&amp;nbsp; filename zipfile zip "&amp;amp;ziploc";&lt;/P&gt;&lt;P&gt;ERROR: Invalid device type.&lt;/P&gt;&lt;P&gt;ERROR: Error in the FILENAME statement.&lt;/P&gt;&lt;P&gt;47&lt;/P&gt;&lt;P&gt;48&amp;nbsp;&amp;nbsp; data _null_;&lt;/P&gt;&lt;P&gt;49&lt;/P&gt;&lt;P&gt;50&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; infile zipfile("&amp;amp;basename..xls") recfm=f lrecl=1;&lt;/P&gt;&lt;P&gt;51&lt;/P&gt;&lt;P&gt;52&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; file "&amp;amp;xlsfile" recfm=f lrecl=1;&lt;/P&gt;&lt;P&gt;53&lt;/P&gt;&lt;P&gt;54&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; input ch $char1.;&lt;/P&gt;&lt;P&gt;55&lt;/P&gt;&lt;P&gt;56&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; put ch $char1.;&lt;/P&gt;&lt;P&gt;57&lt;/P&gt;&lt;P&gt;58&amp;nbsp;&amp;nbsp; run;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ERROR: No logical assign for filename ZIPFILE.&lt;/P&gt;&lt;P&gt;ERROR: Physical file does not exist, C:\Users\venkatnaveen\AppData\Local\Temp\ads_vintages.xls.&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;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; real time&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.01 seconds&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; cpu time&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.01 seconds&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;59&lt;/P&gt;&lt;P&gt;60&amp;nbsp;&amp;nbsp; filename zipfile clear;&lt;/P&gt;&lt;P&gt;WARNING: No logical assign for filename ZIPFILE.&lt;/P&gt;&lt;P&gt;61&lt;/P&gt;&lt;P&gt;62&amp;nbsp;&amp;nbsp; proc import datafile="&amp;amp;xlsfile" out=want&lt;/P&gt;&lt;P&gt;63&lt;/P&gt;&lt;P&gt;64&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; dbms=xls replace&lt;/P&gt;&lt;P&gt;65&lt;/P&gt;&lt;P&gt;66&amp;nbsp;&amp;nbsp; ;&lt;/P&gt;&lt;P&gt;67&lt;/P&gt;&lt;P&gt;68&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; getnames=yes;&lt;/P&gt;&lt;P&gt;69&lt;/P&gt;&lt;P&gt;70&amp;nbsp;&amp;nbsp; run;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ERROR: Physical file does not exist, C:\Users\venkatnaveen\AppData\Local\Temp\ads_vintages.xls.&lt;/P&gt;&lt;P&gt;NOTE: The SAS System stopped processing this step because of errors.&lt;/P&gt;&lt;P&gt;NOTE: PROCEDURE IMPORT used (Total process time):&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; real time&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.96 seconds&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; cpu time&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.00 seconds&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 24 Sep 2014 14:12:30 GMT</pubDate>
    <dc:creator>venkatnaveen</dc:creator>
    <dc:date>2014-09-24T14:12:30Z</dc:date>
    <item>
      <title>Importing xls directly from Zip files</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Importing-xls-directly-from-Zip-files/m-p/155036#M40714</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi &lt;/P&gt;&lt;P&gt;I am having trouble importing xls files contained in Zip files and below is the code. &lt;/P&gt;&lt;P&gt;Below code up to downloading the Zip file should be fine as I was following instructions from SAS blog and I was able to import txt files successfully.&lt;/P&gt;&lt;P&gt;but I'm not sure how to do the same with xls files contained in a Zip, so if anyone knows how to do this, I really appreciate your help.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The error msg I got is below and I think I need to specify xls file name contained in the Zip because I only specified zip file location, but I could not find similar example online and I'm not sure how to specify this.&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #ff0000;"&gt;ERROR: Physical file does not exist, C:\Users\&lt;/SPAN&gt;&lt;SPAN style="color: #ff0000; font-size: 10pt; line-height: 1.5em;"&gt;datafile.zip.xls.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;/* detect proper delim for UNIX vs. Windows */&lt;/P&gt;&lt;P&gt;%let delim=%sysfunc(ifc(%eval(&amp;amp;sysscp. = WIN),\,/));&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;/* create a name for our downloaded ZIP */&lt;/P&gt;&lt;P&gt;%let ziploc = %sysfunc(getoption(work))&amp;amp;delim.datafile.zip;&lt;/P&gt;&lt;P&gt;filename download "&amp;amp;ziploc";&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;/* Download the ZIP file from the Internet*/&lt;/P&gt;&lt;P&gt;proc http&lt;/P&gt;&lt;P&gt; method='GET'&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt; url="&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="http://www.philadelphiafed.org/research-and-data/real-time-center/business-conditions-index/ads_vintages.zip"&gt;http://www.philadelphiafed.org/research-and-data/real-time-center/business-conditions-index/ads_vintages.zip&lt;/A&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt; out=download;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;/* Import an excel file directly from the ZIP */&lt;/P&gt;&lt;P&gt;PROC IMPORT OUT= WORK.test &lt;/P&gt;&lt;P&gt;DATAFILE= "&amp;amp;ziploc"&lt;/P&gt;&lt;P&gt;DBMS=xls REPLACE;&lt;/P&gt;&lt;P&gt;GETNAMES=YES;&lt;/P&gt;&lt;P&gt;DATAROW=2; &lt;/P&gt;&lt;P&gt;RUN; &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 22 Sep 2014 20:55:29 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Importing-xls-directly-from-Zip-files/m-p/155036#M40714</guid>
      <dc:creator>blue_lion</dc:creator>
      <dc:date>2014-09-22T20:55:29Z</dc:date>
    </item>
    <item>
      <title>Re: Importing xls directly from Zip files</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Importing-xls-directly-from-Zip-files/m-p/155037#M40715</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Did you actually get a file downloaded?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 22 Sep 2014 23:10:53 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Importing-xls-directly-from-Zip-files/m-p/155037#M40715</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2014-09-22T23:10:53Z</dc:date>
    </item>
    <item>
      <title>Re: Importing xls directly from Zip files</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Importing-xls-directly-from-Zip-files/m-p/155038#M40716</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You should have been able to make a filename pointing to the ZIP file using the ZIP engine (at least in SAS 9,4).&lt;/P&gt;&lt;P&gt;filename zipfile zip "&amp;amp;ziploc";&lt;/P&gt;&lt;P&gt;And then reference the XLS file within that by using ZIPFILE("ads_vintages.xls") .&lt;/P&gt;&lt;P&gt;But PROC IMPORT is not smart enough to recognize that perfectly normal SAS syntax.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New';"&gt;4 proc import datafile=zipfile("&amp;amp;basename..xls") out=want&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New';"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; -&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New';"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 22&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New';"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 200&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New';"&gt;ERROR 22-322: Syntax error, expecting one of the following: ;, DATAFILE,&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New';"&gt; DATATABLE, DBMS, DEBUG, FILE, OUT, REPLACE, TABLE,&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New';"&gt; _DEBUG_.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New';"&gt;ERROR 200-322: The symbol is not recognized and will be ignored.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So you will need to first copy the XLS file out of the ZIP file before you can point PROC IMPORT to it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;%let&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt; path=c:\downloads;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;%let&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt; basename=ads_vintages;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;%let&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt; ziploc=&amp;amp;path\&amp;amp;basename..zip ;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;%let&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt; xlsfile=&amp;amp;path\&amp;amp;basename..xls ;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;filename&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt; zipfile zip &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: purple; background: white;"&gt;"&amp;amp;ziploc"&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;STRONG style="color: navy; background: white; font-size: 10.0pt; font-family: 'Courier New';"&gt;data&lt;/STRONG&gt; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;_null_&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&amp;nbsp; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;infile&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt; zipfile(&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: purple; background: white;"&gt;"&amp;amp;basename..xls"&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt;) &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;recfm&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt;=f &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;lrecl&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt;=&lt;/SPAN&gt;&lt;STRONG style="color: teal; background: white; font-size: 10.0pt; font-family: 'Courier New';"&gt;1&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&amp;nbsp; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;file&lt;/SPAN&gt; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: purple; background: white;"&gt;"&amp;amp;xlsfile"&lt;/SPAN&gt; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;recfm&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt;=f &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;lrecl&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt;=&lt;/SPAN&gt;&lt;STRONG style="color: teal; background: white; font-size: 10.0pt; font-family: 'Courier New';"&gt;1&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&amp;nbsp; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;input&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt; ch &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: teal; background: white;"&gt;$char1.&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&amp;nbsp; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;put&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt; ch &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: teal; background: white;"&gt;$char1.&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;STRONG style="color: navy; background: white; font-size: 10.0pt; font-family: 'Courier New';"&gt;run&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;filename&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt; zipfile &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;clear&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;STRONG style="color: navy; background: white; font-size: 10.0pt; font-family: 'Courier New';"&gt;proc&lt;/STRONG&gt; &lt;STRONG style="color: navy; background: white; font-size: 10.0pt; font-family: 'Courier New';"&gt;import&lt;/STRONG&gt; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;datafile&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: purple; background: white;"&gt;"&amp;amp;xlsfile"&lt;/SPAN&gt; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;out&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt;=want&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&amp;nbsp; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;dbms&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt;=xls replace &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&amp;nbsp; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;getnames&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt;=yes;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="color: navy; background: white; font-size: 10.0pt; font-family: 'Courier New';"&gt;run&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 23 Sep 2014 01:09:45 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Importing-xls-directly-from-Zip-files/m-p/155038#M40716</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2014-09-23T01:09:45Z</dc:date>
    </item>
    <item>
      <title>Re: Importing xls directly from Zip files</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Importing-xls-directly-from-Zip-files/m-p/155039#M40717</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Tom,&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;Thank you for clarifying everything. &lt;SPAN style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;Copying the XLS file method works beautifully!&lt;/SPAN&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;I did not know PROC IMPORT cannot recognize &lt;SPAN style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;ZIPFILE("ads_vintages.xls").&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: #ffffff; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;That is how I tried to code initially because I was able to do so with txt files, but I also got error message and I removed the line.&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;Thank you very much! &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 23 Sep 2014 16:17:50 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Importing-xls-directly-from-Zip-files/m-p/155039#M40717</guid>
      <dc:creator>blue_lion</dc:creator>
      <dc:date>2014-09-23T16:17:50Z</dc:date>
    </item>
    <item>
      <title>Re: Importing xls directly from Zip files</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Importing-xls-directly-from-Zip-files/m-p/155040#M40718</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Tom I m getting folowing error when trying on sas 9.2 version.&lt;/P&gt;&lt;P&gt;Does zip engine support 9.2 version?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; %let path=C:\Users\venkatnaveen\AppData\Local\Temp;&lt;/P&gt;&lt;P&gt;39&lt;/P&gt;&lt;P&gt;40&amp;nbsp;&amp;nbsp; %let basename=ads_vintages;&lt;/P&gt;&lt;P&gt;41&lt;/P&gt;&lt;P&gt;42&amp;nbsp;&amp;nbsp; %let ziploc=&amp;amp;path\&amp;amp;basename..zip ;&lt;/P&gt;&lt;P&gt;43&lt;/P&gt;&lt;P&gt;44&amp;nbsp;&amp;nbsp; %let xlsfile=&amp;amp;path\&amp;amp;basename..xls ;&lt;/P&gt;&lt;P&gt;45&lt;/P&gt;&lt;P&gt;46&amp;nbsp;&amp;nbsp; filename zipfile zip "&amp;amp;ziploc";&lt;/P&gt;&lt;P&gt;ERROR: Invalid device type.&lt;/P&gt;&lt;P&gt;ERROR: Error in the FILENAME statement.&lt;/P&gt;&lt;P&gt;47&lt;/P&gt;&lt;P&gt;48&amp;nbsp;&amp;nbsp; data _null_;&lt;/P&gt;&lt;P&gt;49&lt;/P&gt;&lt;P&gt;50&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; infile zipfile("&amp;amp;basename..xls") recfm=f lrecl=1;&lt;/P&gt;&lt;P&gt;51&lt;/P&gt;&lt;P&gt;52&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; file "&amp;amp;xlsfile" recfm=f lrecl=1;&lt;/P&gt;&lt;P&gt;53&lt;/P&gt;&lt;P&gt;54&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; input ch $char1.;&lt;/P&gt;&lt;P&gt;55&lt;/P&gt;&lt;P&gt;56&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; put ch $char1.;&lt;/P&gt;&lt;P&gt;57&lt;/P&gt;&lt;P&gt;58&amp;nbsp;&amp;nbsp; run;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ERROR: No logical assign for filename ZIPFILE.&lt;/P&gt;&lt;P&gt;ERROR: Physical file does not exist, C:\Users\venkatnaveen\AppData\Local\Temp\ads_vintages.xls.&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;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; real time&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.01 seconds&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; cpu time&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.01 seconds&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;59&lt;/P&gt;&lt;P&gt;60&amp;nbsp;&amp;nbsp; filename zipfile clear;&lt;/P&gt;&lt;P&gt;WARNING: No logical assign for filename ZIPFILE.&lt;/P&gt;&lt;P&gt;61&lt;/P&gt;&lt;P&gt;62&amp;nbsp;&amp;nbsp; proc import datafile="&amp;amp;xlsfile" out=want&lt;/P&gt;&lt;P&gt;63&lt;/P&gt;&lt;P&gt;64&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; dbms=xls replace&lt;/P&gt;&lt;P&gt;65&lt;/P&gt;&lt;P&gt;66&amp;nbsp;&amp;nbsp; ;&lt;/P&gt;&lt;P&gt;67&lt;/P&gt;&lt;P&gt;68&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; getnames=yes;&lt;/P&gt;&lt;P&gt;69&lt;/P&gt;&lt;P&gt;70&amp;nbsp;&amp;nbsp; run;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ERROR: Physical file does not exist, C:\Users\venkatnaveen\AppData\Local\Temp\ads_vintages.xls.&lt;/P&gt;&lt;P&gt;NOTE: The SAS System stopped processing this step because of errors.&lt;/P&gt;&lt;P&gt;NOTE: PROCEDURE IMPORT used (Total process time):&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; real time&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.96 seconds&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; cpu time&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.00 seconds&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 24 Sep 2014 14:12:30 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Importing-xls-directly-from-Zip-files/m-p/155040#M40718</guid>
      <dc:creator>venkatnaveen</dc:creator>
      <dc:date>2014-09-24T14:12:30Z</dc:date>
    </item>
    <item>
      <title>Re: Importing xls directly from Zip files</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Importing-xls-directly-from-Zip-files/m-p/155041#M40719</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I think this was a SAS 9.4 enhancement:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://blogs.sas.com/content/sasdummy/2014/01/29/using-filename-zip/" title="http://blogs.sas.com/content/sasdummy/2014/01/29/using-filename-zip/"&gt; Reading and updating ZIP files with FILENAME ZIP - The SAS Dummy&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 24 Sep 2014 19:31:35 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Importing-xls-directly-from-Zip-files/m-p/155041#M40719</guid>
      <dc:creator>SASKiwi</dc:creator>
      <dc:date>2014-09-24T19:31:35Z</dc:date>
    </item>
  </channel>
</rss>

