<?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: How to read a range of cells from Excel ? in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/How-to-read-a-range-of-cells-from-Excel/m-p/817085#M322521</link>
    <description>&lt;P&gt;Sounds like you have the same issue as &lt;A href="https://communities.sas.com/t5/SAS-Enterprise-Guide/proc-import/m-p/817075#M40819" target="_self"&gt;this other question&lt;/A&gt;.&lt;/P&gt;
&lt;P&gt;Just tell it where to start.&amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc import
   datafile = "C:\CR-6365.xlsx"
  DBMS = xlsx
  OUT = a1 REPLACE
;
  range =  "PQCs For CRAs$A5:";
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Wed, 08 Jun 2022 14:03:25 GMT</pubDate>
    <dc:creator>Tom</dc:creator>
    <dc:date>2022-06-08T14:03:25Z</dc:date>
    <item>
      <title>How to read a range of cells from Excel ?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-read-a-range-of-cells-from-Excel/m-p/817078#M322519</link>
      <description>&lt;P&gt;Hi All,&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I am trying to get the data from an excel sheet into the sas dataset. I need the data in excel sheet starting from row 6 and row 5 should be a column names. When I tried to get this with below code its giving me an error( Statement is not valid or it is used out of proper order) for the last 4 statements(mixed,&amp;nbsp; namerow, startrow, endrow). Can anyone please suggest me any other alternate way on this.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;proc import datafile = "C:\CR-6365.xlsx" &lt;BR /&gt;DBMS = xlsx&lt;BR /&gt;OUT = a1&lt;BR /&gt;REPLACE;;&lt;BR /&gt;sheet = "PQCs For CRAs";&lt;BR /&gt;GETNAMES =Yes;&lt;BR /&gt;Mixed=YES;&lt;BR /&gt;namerow=5;&lt;BR /&gt;startrow=6;&lt;BR /&gt;endrow=16;&lt;BR /&gt;quit;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks,&lt;/P&gt;
&lt;P&gt;Kumar.&lt;/P&gt;</description>
      <pubDate>Wed, 08 Jun 2022 13:42:47 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-read-a-range-of-cells-from-Excel/m-p/817078#M322519</guid>
      <dc:creator>Kumar6</dc:creator>
      <dc:date>2022-06-08T13:42:47Z</dc:date>
    </item>
    <item>
      <title>Re: How to read a range of cells from Excel ?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-read-a-range-of-cells-from-Excel/m-p/817084#M322520</link>
      <description>&lt;P&gt;Maxim 1: Read the Documentation.&lt;/P&gt;
&lt;P&gt;In this case, the specific page for&amp;nbsp;&lt;A href="https://documentation.sas.com/doc/en/pgmsascdc/9.4_3.5/acpcref/n0msy4hy1so0ren1acm90iijxn8j.htm" target="_blank" rel="noopener"&gt;Microsoft Workbook Files&lt;/A&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;There are no NAMEROW, STARTROW or ENDROW statements for DBMS=XLSX (only for DBMS=XLS).&lt;/P&gt;
&lt;P&gt;Instead, use a RANGE= statement to direct SAS to the correct part of the spreadsheet. The specific part for the RANGE statement is &lt;A href="https://documentation.sas.com/doc/en/pgmsascdc/9.4_3.5/acpcref/n0msy4hy1so0ren1acm90iijxn8j.htm#p1txjpgmbho31yn1dsd73if91fmj" target="_blank" rel="noopener"&gt;here&lt;/A&gt;.&lt;/P&gt;</description>
      <pubDate>Wed, 08 Jun 2022 13:55:05 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-read-a-range-of-cells-from-Excel/m-p/817084#M322520</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2022-06-08T13:55:05Z</dc:date>
    </item>
    <item>
      <title>Re: How to read a range of cells from Excel ?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-read-a-range-of-cells-from-Excel/m-p/817085#M322521</link>
      <description>&lt;P&gt;Sounds like you have the same issue as &lt;A href="https://communities.sas.com/t5/SAS-Enterprise-Guide/proc-import/m-p/817075#M40819" target="_self"&gt;this other question&lt;/A&gt;.&lt;/P&gt;
&lt;P&gt;Just tell it where to start.&amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc import
   datafile = "C:\CR-6365.xlsx"
  DBMS = xlsx
  OUT = a1 REPLACE
;
  range =  "PQCs For CRAs$A5:";
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Wed, 08 Jun 2022 14:03:25 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-read-a-range-of-cells-from-Excel/m-p/817085#M322521</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2022-06-08T14:03:25Z</dc:date>
    </item>
    <item>
      <title>Re: How to read a range of cells from Excel ?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-read-a-range-of-cells-from-Excel/m-p/817115#M322529</link>
      <description>It worked. Thank You.</description>
      <pubDate>Wed, 08 Jun 2022 15:05:19 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-read-a-range-of-cells-from-Excel/m-p/817115#M322529</guid>
      <dc:creator>Kumar6</dc:creator>
      <dc:date>2022-06-08T15:05:19Z</dc:date>
    </item>
  </channel>
</rss>

