<?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 excel file using libname statement in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Importing-excel-file-using-libname-statement/m-p/406197#M279273</link>
    <description>&lt;P&gt;Can you share&amp;nbsp;an example of the&amp;nbsp;libname statement that is generating the error?&lt;/P&gt;</description>
    <pubDate>Sat, 21 Oct 2017 00:51:35 GMT</pubDate>
    <dc:creator>spalm</dc:creator>
    <dc:date>2017-10-21T00:51:35Z</dc:date>
    <item>
      <title>Importing excel file using libname statement</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Importing-excel-file-using-libname-statement/m-p/406160#M279272</link>
      <description>&lt;P&gt;I wanted to import sheet from excel (xlsx, SAS 9.4) named "TS" using libname&amp;nbsp; statement, but I got such message:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;No cell rectangle in range&lt;BR /&gt;Requested Input File Is Invalid&lt;BR /&gt;ERROR: File EXCELLIB.TS.DATA does not exist.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;When I use proc import, it works. Also it works when I am changing the sheet name like "TSO". I have other&amp;nbsp; sheets named AE/IE etc. for which libname works without any problem. Could you please help me to find where from the issue can&amp;nbsp; come (it is from code, from excel etc. )&lt;/P&gt;</description>
      <pubDate>Fri, 20 Oct 2017 21:27:31 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Importing-excel-file-using-libname-statement/m-p/406160#M279272</guid>
      <dc:creator>Anahit</dc:creator>
      <dc:date>2017-10-20T21:27:31Z</dc:date>
    </item>
    <item>
      <title>Re: Importing excel file using libname statement</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Importing-excel-file-using-libname-statement/m-p/406197#M279273</link>
      <description>&lt;P&gt;Can you share&amp;nbsp;an example of the&amp;nbsp;libname statement that is generating the error?&lt;/P&gt;</description>
      <pubDate>Sat, 21 Oct 2017 00:51:35 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Importing-excel-file-using-libname-statement/m-p/406197#M279273</guid>
      <dc:creator>spalm</dc:creator>
      <dc:date>2017-10-21T00:51:35Z</dc:date>
    </item>
    <item>
      <title>Re: Importing excel file using libname statement</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Importing-excel-file-using-libname-statement/m-p/406255#M279274</link>
      <description>&lt;P&gt;Sure, please:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;LIBNAME gx xlsx ".D:\Desktop\Anahit\XX.xlsx" ;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;data df;&lt;BR /&gt;set gx.TS;&lt;BR /&gt;run;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Just want to mention that this code work perfectly with other sheets of the&amp;nbsp; same file.&lt;/P&gt;</description>
      <pubDate>Sat, 21 Oct 2017 14:43:14 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Importing-excel-file-using-libname-statement/m-p/406255#M279274</guid>
      <dc:creator>Anahit</dc:creator>
      <dc:date>2017-10-21T14:43:14Z</dc:date>
    </item>
    <item>
      <title>Re: Importing excel file using libname statement</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Importing-excel-file-using-libname-statement/m-p/406258#M279275</link>
      <description>&lt;P&gt;Submit the problem to SAS technical support. I was able to replicate the problem using a simple workbook with three worksheets named TSO, TS and SO. The three worksheets were identical with only two variables x and y named on the first row, followed by values on the 2nd and 3rd rows.&amp;nbsp; Worked perfectly for TSO and SO, but received the same error message you got when trying to read the TS worksheet.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Art, CEO, AnalystFinder.com&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 21 Oct 2017 15:13:12 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Importing-excel-file-using-libname-statement/m-p/406258#M279275</guid>
      <dc:creator>art297</dc:creator>
      <dc:date>2017-10-21T15:13:12Z</dc:date>
    </item>
    <item>
      <title>Re: Importing excel file using libname statement</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Importing-excel-file-using-libname-statement/m-p/406262#M279276</link>
      <description>&lt;P&gt;Unfortunately, the problem appears to be intermittent. The first time I ran the code I got the exact same error message as you did.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I had run it on SAS UE using VMWare on Chrome.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Interestingly, I got the error message, the log showed that the other two files had imported correctly, but the output menu didn't appear, so I wasn't able to look at the files.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Since then, I've been unable to replicate the problem. I even cold booted my system, but now everything imports correctly.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In short, this one is confusing! I'd still raise it with Technical Support as our both getting the same error message, to me, is enough evidence that something is wrong.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Art, CEO, AnalystFinder.com&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 21 Oct 2017 16:08:36 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Importing-excel-file-using-libname-statement/m-p/406262#M279276</guid>
      <dc:creator>art297</dc:creator>
      <dc:date>2017-10-21T16:08:36Z</dc:date>
    </item>
    <item>
      <title>Re: Importing excel file using libname statement</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Importing-excel-file-using-libname-statement/m-p/407676#M279277</link>
      <description>&lt;P&gt;Hello Art,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I found the solution. I removed all hidden names from excel using visual basic and it worked. So problem was related to excel,not SAS. Thank you.&lt;/P&gt;</description>
      <pubDate>Thu, 26 Oct 2017 15:13:39 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Importing-excel-file-using-libname-statement/m-p/407676#M279277</guid>
      <dc:creator>Anahit</dc:creator>
      <dc:date>2017-10-26T15:13:39Z</dc:date>
    </item>
    <item>
      <title>Re: Importing excel file using libname statement</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Importing-excel-file-using-libname-statement/m-p/407687#M279278</link>
      <description>&lt;P&gt;Glad you found a solution but, on the other hand, I'm not sure what the problem is/was.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;When I first ran your code on a workbook that I created (which didn't have any hidden names), I got the same error as you did.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;However, that only happened the first time and, since then (importing the same workbook), I haven't been able to replicate the problem. The workbook keeps importing correctly ,, even though I haven't changed it.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Art, CEO, AnalystFinder.com&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 26 Oct 2017 15:36:01 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Importing-excel-file-using-libname-statement/m-p/407687#M279278</guid>
      <dc:creator>art297</dc:creator>
      <dc:date>2017-10-26T15:36:01Z</dc:date>
    </item>
    <item>
      <title>Re: Importing excel file using libname statement</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Importing-excel-file-using-libname-statement/m-p/407712#M279279</link>
      <description>&lt;P&gt;Before finding the&amp;nbsp; solution (in my case) , I had written to&amp;nbsp;&lt;SPAN&gt;SAS Technical Support and here their answer:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P class="m_7630763035811315392cs95E872D0"&gt;&lt;SPAN class="m_7630763035811315392cs8A70F0C8"&gt;Hello Anahit,&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="m_7630763035811315392cs95E872D0"&gt;&lt;SPAN class="m_7630763035811315392cs8A70F0C8"&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="m_7630763035811315392cs95E872D0"&gt;&lt;SPAN class="m_7630763035811315392cs8A70F0C8"&gt;When I attempt to replicate this with on the file provided it works as expected:&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="m_7630763035811315392cs95E872D0"&gt;&lt;SPAN class="m_7630763035811315392cs8A70F0C8"&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="m_7630763035811315392cs95E872D0"&gt;&lt;SPAN class="m_7630763035811315392csBCB4C014"&gt;4 &amp;nbsp;&amp;nbsp;&amp;nbsp;libname xl xlsx "C:\testing\7612261489\data.xlsx";&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="m_7630763035811315392cs95E872D0"&gt;&lt;SPAN class="m_7630763035811315392csBCB4C014"&gt;NOTE: Libref XL was successfully assigned as follows:&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="m_7630763035811315392cs95E872D0"&gt;&lt;SPAN class="m_7630763035811315392csBCB4C014"&gt;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;Engine: &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;XLSX&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="m_7630763035811315392cs95E872D0"&gt;&lt;SPAN class="m_7630763035811315392csBCB4C014"&gt;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;Physical Name: C:\testing\7612261489\data.xlsx&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="m_7630763035811315392cs95E872D0"&gt;&lt;SPAN class="m_7630763035811315392csBCB4C014"&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="m_7630763035811315392cs95E872D0"&gt;&lt;SPAN class="m_7630763035811315392csBCB4C014"&gt;5 &amp;nbsp;&amp;nbsp;&amp;nbsp;data newx;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="m_7630763035811315392cs95E872D0"&gt;&lt;SPAN class="m_7630763035811315392csBCB4C014"&gt;6 &amp;nbsp;&amp;nbsp;&amp;nbsp;set xl.TS;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="m_7630763035811315392cs95E872D0"&gt;&lt;SPAN class="m_7630763035811315392csBCB4C014"&gt;7 &amp;nbsp;&amp;nbsp;&amp;nbsp;run;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="m_7630763035811315392cs95E872D0"&gt;&lt;SPAN class="m_7630763035811315392csBCB4C014"&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="m_7630763035811315392cs95E872D0"&gt;&lt;SPAN class="m_7630763035811315392csBCB4C014"&gt;NOTE: The import data set has 26 observations and 10 variables.&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="m_7630763035811315392cs95E872D0"&gt;&lt;SPAN class="m_7630763035811315392csBCB4C014"&gt;NOTE: There were 26 observations read from the data set XL.TS.&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="m_7630763035811315392cs95E872D0"&gt;&lt;SPAN class="m_7630763035811315392csBCB4C014"&gt;NOTE: The data set WORK.NEWX has 26 observations and 10 variables.&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="m_7630763035811315392cs95E872D0"&gt;&lt;SPAN class="m_7630763035811315392csBCB4C014"&gt;NOTE: DATA statement used (Total process time):&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="m_7630763035811315392cs95E872D0"&gt;&lt;SPAN class="m_7630763035811315392csBCB4C014"&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.02 seconds&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="m_7630763035811315392cs95E872D0"&gt;&lt;SPAN class="m_7630763035811315392csBCB4C014"&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;/SPAN&gt;&lt;/P&gt;&lt;P class="m_7630763035811315392cs95E872D0"&gt;&lt;SPAN class="m_7630763035811315392cs8A70F0C8"&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="m_7630763035811315392cs95E872D0"&gt;&lt;SPAN class="m_7630763035811315392cs8A70F0C8"&gt;I suspect two possible issues. First, Excel can sometimes have issues with import/export when sheet names use only two or three characters. This is usually not an issue for the XLSX engine you are using. However the core issue is rooted in how ranges, sheet names, and cell references are stored and accessed. It is possible for a range to become mismatched from its sheet or cell(s) and thus cause an error such as this. Second possible issue would be some minor corruption in the original Excel file. When the file is modified or recreated the corruption is corrected and thus the error is resolved. Unfortunately neither case is something we can diagnosis from withing SAS.&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="m_7630763035811315392cs95E872D0"&gt;&lt;SPAN class="m_7630763035811315392cs8A70F0C8"&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="m_7630763035811315392cs95E872D0"&gt;&lt;SPAN class="m_7630763035811315392cs8A70F0C8"&gt;Now I do have one known issue where this error is reported but it has not been reported in your specific situation. This error is noted in SAS Note 60543&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;A href="http://support.sas.com/kb/60543" target="_blank"&gt;&lt;SPAN class="m_7630763035811315392cs896CB680"&gt;http://support.sas.com/kb/60543&lt;/SPAN&gt;&lt;/A&gt;&lt;/SPAN&gt;&lt;SPAN class="m_7630763035811315392cs8A70F0C8"&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;and is fixed in the hot fix referenced in that note. It would not be a bad idea to apply that hot fix to your installation.&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="m_7630763035811315392cs95E872D0"&gt;&lt;SPAN class="m_7630763035811315392cs8A70F0C8"&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 26 Oct 2017 16:28:14 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Importing-excel-file-using-libname-statement/m-p/407712#M279279</guid>
      <dc:creator>Anahit</dc:creator>
      <dc:date>2017-10-26T16:28:14Z</dc:date>
    </item>
  </channel>
</rss>

