<?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: Proc IMPORT won't read data from excel file in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Proc-IMPORT-won-t-read-data-from-excel-file/m-p/437375#M108882</link>
    <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/97352"&gt;@AaronJ&lt;/a&gt; wrote:&lt;BR /&gt;yes, i am aware of that. and there are still 270 lines of data with numbers in them for each of the variables that SAS is not reading.&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Are you basing the above statement from looking at the data in the original Excel files?&lt;/P&gt;
&lt;P&gt;You may be thinking you have species values=1 or measurement&amp;nbsp;values =2 that are actually 1.01 or .99 (for species) or 2.01 or 1.99 because the display in Excel was set to no decimals.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You might want to print some of those records you think should be included from the IMPORT set to show the values of measurement, gld, dbh and height.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;It also helps to be consistent: Original post:&lt;/P&gt;
&lt;PRE&gt;if Measurement=2;
if GLD&amp;gt;0;
if DBH&amp;gt;0;
if Height&amp;gt;0;&lt;/PRE&gt;
&lt;P&gt;in the longer code example:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;74 if Species=1;
75 if Measurement=2;
76 if GLD&amp;gt;0.01;
77 if DBH&amp;gt;0.01;
78 if Height&amp;gt;0.01;&lt;/PRE&gt;
&lt;P&gt;which is more restrictive than with the addition of Species and increasing the limits of the last three variables.&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;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;BTW I notice you have code like this:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;DIV class="sasSource"&gt;85 /*proc univariate Normal Plot data=&lt;FONT color="#ff0000"&gt;Trees&lt;/FONT&gt;;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;86 var GLD DBH Height;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;87 by Tree Measurement;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;88 Histogram GLD DBH Height/Normal;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;89 QQPLOT GLD DBH Height;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;90 output out=&lt;FONT color="#ff0000"&gt;Trees&lt;/FONT&gt;;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;91 run;*/&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;The first time you run this code you will replace your input set if that is actually executed. You need to be very aware of using that type of code in longer programs.&lt;/DIV&gt;</description>
    <pubDate>Wed, 14 Feb 2018 23:18:47 GMT</pubDate>
    <dc:creator>ballardw</dc:creator>
    <dc:date>2018-02-14T23:18:47Z</dc:date>
    <item>
      <title>Proc IMPORT won't read data from excel file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Proc-IMPORT-won-t-read-data-from-excel-file/m-p/436906#M108720</link>
      <description>&lt;P&gt;I am trying to import data from an excel file into SAS University. I have 5 species and a dozen or so variables.&lt;/P&gt;&lt;P&gt;When i run Proc IMPORT and Proc PRINT of the data it will read some of the Species and their rows of data, but not all. In fact, it will read 3 rows of data but not the other 275.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Why isn't SAS reading data that is clearly visible in the excel file itself? or How can i force SAS to read the data that it won't?&lt;/P&gt;&lt;P&gt;this is the code i've written:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;%web_drop_table(WORK.IMPORT);&lt;/P&gt;&lt;P&gt;FILENAME FILEREF '/folders/myfolders/Trees.xlsx';&lt;/P&gt;&lt;P&gt;PROC IMPORT DATAFILE=FILEREF&lt;BR /&gt;DBMS=XLSX&lt;BR /&gt;OUT=WORK.IMPORT;&lt;BR /&gt;GETNAMES=YES;&lt;BR /&gt;RUN;&lt;/P&gt;&lt;P&gt;data Trees;&lt;BR /&gt;set import;&lt;BR /&gt;if Measurement=2;&lt;BR /&gt;if GLD&amp;gt;0;&lt;BR /&gt;if DBH&amp;gt;0;&lt;BR /&gt;if Height&amp;gt;0;&lt;BR /&gt;&lt;BR /&gt;run;&lt;BR /&gt;&lt;BR /&gt;proc print data=Trees;&lt;BR /&gt;run;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks in advance&lt;/P&gt;</description>
      <pubDate>Tue, 13 Feb 2018 22:32:59 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Proc-IMPORT-won-t-read-data-from-excel-file/m-p/436906#M108720</guid>
      <dc:creator>AaronJ</dc:creator>
      <dc:date>2018-02-13T22:32:59Z</dc:date>
    </item>
    <item>
      <title>Re: Proc IMPORT won't read data from excel file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Proc-IMPORT-won-t-read-data-from-excel-file/m-p/436915#M108725</link>
      <description>&lt;P&gt;FILEREF may be a keyword, try changing your FILENAME reference to have a different word.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;FILENAME myfile '/folders/myfolders/Trees.xlsx';

PROC IMPORT DATAFILE=myfile
DBMS=XLSX
OUT=WORK.IMPORT;
GETNAMES=YES;
RUN;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;And post your log.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/97352"&gt;@AaronJ&lt;/a&gt; wrote:&lt;BR /&gt;
&lt;P&gt;I am trying to import data from an excel file into SAS University. I have 5 species and a dozen or so variables.&lt;/P&gt;
&lt;P&gt;When i run Proc IMPORT and Proc PRINT of the data it will read some of the Species and their rows of data, but not all. In fact, it will read 3 rows of data but not the other 275.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Why isn't SAS reading data that is clearly visible in the excel file itself? or How can i force SAS to read the data that it won't?&lt;/P&gt;
&lt;P&gt;this is the code i've written:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;%web_drop_table(WORK.IMPORT);&lt;/P&gt;
&lt;P&gt;FILENAME FILEREF '/folders/myfolders/Trees.xlsx';&lt;/P&gt;
&lt;P&gt;PROC IMPORT DATAFILE=FILEREF&lt;BR /&gt;DBMS=XLSX&lt;BR /&gt;OUT=WORK.IMPORT;&lt;BR /&gt;GETNAMES=YES;&lt;BR /&gt;RUN;&lt;/P&gt;
&lt;P&gt;data Trees;&lt;BR /&gt;set import;&lt;BR /&gt;if Measurement=2;&lt;BR /&gt;if GLD&amp;gt;0;&lt;BR /&gt;if DBH&amp;gt;0;&lt;BR /&gt;if Height&amp;gt;0;&lt;BR /&gt;&lt;BR /&gt;run;&lt;BR /&gt;&lt;BR /&gt;proc print data=Trees;&lt;BR /&gt;run;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks in advance&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 13 Feb 2018 22:59:35 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Proc-IMPORT-won-t-read-data-from-excel-file/m-p/436915#M108725</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2018-02-13T22:59:35Z</dc:date>
    </item>
    <item>
      <title>Re: Proc IMPORT won't read data from excel file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Proc-IMPORT-won-t-read-data-from-excel-file/m-p/436936#M108736</link>
      <description>&lt;P&gt;Which data set only has 3 rows of data? Work.import or work.trees?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In&lt;/P&gt;
&lt;P&gt;data Trees;&lt;BR /&gt;set import;&lt;BR /&gt;&lt;FONT color="#ff0000"&gt;if Measurement=2;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#ff0000"&gt;if GLD&amp;gt;0;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#ff0000"&gt;if DBH&amp;gt;0;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#ff0000"&gt;if Height&amp;gt;0;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#000000"&gt;Each of those If statements removed records. Your proc print should only show the records where Measurement=2 &lt;STRONG&gt;and&lt;/STRONG&gt; GLD&amp;gt;0 &lt;STRONG&gt;and &lt;/STRONG&gt;DBH&amp;gt;0 &lt;STRONG&gt;and &lt;/STRONG&gt;height &amp;gt; 0 because you removed everything else in the set import when writing it to Trees.&lt;/FONT&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 14 Feb 2018 00:13:14 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Proc-IMPORT-won-t-read-data-from-excel-file/m-p/436936#M108736</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2018-02-14T00:13:14Z</dc:date>
    </item>
    <item>
      <title>Re: Proc IMPORT won't read data from excel file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Proc-IMPORT-won-t-read-data-from-excel-file/m-p/436980#M108754</link>
      <description>yes, i am aware of that. and there are still 270 lines of data with numbers in them for each of the variables that SAS is not reading.</description>
      <pubDate>Wed, 14 Feb 2018 03:29:08 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Proc-IMPORT-won-t-read-data-from-excel-file/m-p/436980#M108754</guid>
      <dc:creator>AaronJ</dc:creator>
      <dc:date>2018-02-14T03:29:08Z</dc:date>
    </item>
    <item>
      <title>Re: Proc IMPORT won't read data from excel file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Proc-IMPORT-won-t-read-data-from-excel-file/m-p/436985#M108756</link>
      <description>&lt;P&gt;Post your log.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 14 Feb 2018 04:11:25 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Proc-IMPORT-won-t-read-data-from-excel-file/m-p/436985#M108756</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2018-02-14T04:11:25Z</dc:date>
    </item>
    <item>
      <title>Re: Proc IMPORT won't read data from excel file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Proc-IMPORT-won-t-read-data-from-excel-file/m-p/437130#M108812</link>
      <description>&lt;P&gt;Here's the log:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;DIV class="sasSource"&gt;1 OPTIONS NONOTES NOSTIMER NOSOURCE NOSYNTAXCHECK;&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;61&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;62 %web_drop_table(WORK.IMPORT);&lt;/DIV&gt;&lt;DIV class="sasNote"&gt;NOTE: Table WORK.IMPORT has been dropped.&lt;/DIV&gt;&lt;DIV class="sasNote"&gt;NOTE: PROCEDURE SQL used (Total process time):&lt;/DIV&gt;&lt;DIV class="sasNote"&gt;real time 0.01 seconds&lt;/DIV&gt;&lt;DIV class="sasNote"&gt;cpu time 0.00 seconds&lt;/DIV&gt;&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;63&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;64 FILENAME FILEREF '/folders/myfolders/Trees.xlsx';&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;65&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;66 PROC IMPORT DATAFILE=FILEREF&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;67 DBMS=XLSX&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;68 OUT=WORK.IMPORT;&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;69 GETNAMES=YES;&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;70 RUN;&lt;/DIV&gt;&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="sasNote"&gt;NOTE: The import data set has 12488 observations and 21 variables.&lt;/DIV&gt;&lt;DIV class="sasNote"&gt;NOTE: WORK.IMPORT data set was successfully created.&lt;/DIV&gt;&lt;DIV class="sasNote"&gt;NOTE: PROCEDURE IMPORT used (Total process time):&lt;/DIV&gt;&lt;DIV class="sasNote"&gt;real time 6.95 seconds&lt;/DIV&gt;&lt;DIV class="sasNote"&gt;cpu time 6.90 seconds&lt;/DIV&gt;&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;71&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;72 data Trees;&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;73 set import;&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;74 if Species=1;&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;75 if Measurement=2;&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;76 if GLD&amp;gt;0.01;&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;77 if DBH&amp;gt;0.01;&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;78 if Height&amp;gt;0.01;&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;79&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;80 run;&lt;/DIV&gt;&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="sasNote"&gt;NOTE: There were 12488 observations read from the data set WORK.IMPORT.&lt;/DIV&gt;&lt;DIV class="sasNote"&gt;NOTE: The data set WORK.TREES has 3 observations and 21 variables.&lt;/DIV&gt;&lt;DIV class="sasNote"&gt;NOTE: DATA statement used (Total process time):&lt;/DIV&gt;&lt;DIV class="sasNote"&gt;real time 0.02 seconds&lt;/DIV&gt;&lt;DIV class="sasNote"&gt;cpu time 0.03 seconds&lt;/DIV&gt;&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;81&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;82 proc print data=Trees;&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;83 run;&lt;/DIV&gt;&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="sasNote"&gt;NOTE: There were 3 observations read from the data set WORK.TREES.&lt;/DIV&gt;&lt;DIV class="sasNote"&gt;NOTE: PROCEDURE PRINT used (Total process time):&lt;/DIV&gt;&lt;DIV class="sasNote"&gt;real time 0.28 seconds&lt;/DIV&gt;&lt;DIV class="sasNote"&gt;cpu time 0.28 seconds&lt;/DIV&gt;&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;84&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;85 /*proc univariate Normal Plot data=Trees;&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;86 var GLD DBH Height;&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;87 by Tree Measurement;&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;88 Histogram GLD DBH Height/Normal;&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;89 QQPLOT GLD DBH Height;&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;90 output out=Trees;&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;91 run;*/&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;92&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;93 proc sort data=Trees;&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;94 By Species Fert Nfix Block Plot Measurement;&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;95 run;&lt;/DIV&gt;&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="sasNote"&gt;NOTE: There were 3 observations read from the data set WORK.TREES.&lt;/DIV&gt;&lt;DIV class="sasNote"&gt;NOTE: The data set WORK.TREES has 3 observations and 21 variables.&lt;/DIV&gt;&lt;DIV class="sasNote"&gt;NOTE: PROCEDURE SORT used (Total process time):&lt;/DIV&gt;&lt;DIV class="sasNote"&gt;real time 0.01 seconds&lt;/DIV&gt;&lt;DIV class="sasNote"&gt;cpu time 0.02 seconds&lt;/DIV&gt;&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="sasNote"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;96&lt;/DIV&gt;&lt;DIV class="sasSource"&gt;97 OPTIONS NONOTES NOSTIMER NOSOURCE NOSYNTAXCHECK;&lt;/DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;DIV class="sasSource"&gt;110&lt;/DIV&gt;&lt;/DIV&gt;&lt;PRE class="sasLog"&gt;&amp;nbsp;&lt;/PRE&gt;</description>
      <pubDate>Wed, 14 Feb 2018 15:22:49 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Proc-IMPORT-won-t-read-data-from-excel-file/m-p/437130#M108812</guid>
      <dc:creator>AaronJ</dc:creator>
      <dc:date>2018-02-14T15:22:49Z</dc:date>
    </item>
    <item>
      <title>Re: Proc IMPORT won't read data from excel file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Proc-IMPORT-won-t-read-data-from-excel-file/m-p/437158#M108822</link>
      <description>&lt;P&gt;And how many observations and variables were you expecting?&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;NOTE: The import data set has 12488 observations and 21 variables.&lt;/STRONG&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 14 Feb 2018 15:52:25 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Proc-IMPORT-won-t-read-data-from-excel-file/m-p/437158#M108822</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2018-02-14T15:52:25Z</dc:date>
    </item>
    <item>
      <title>Re: Proc IMPORT won't read data from excel file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Proc-IMPORT-won-t-read-data-from-excel-file/m-p/437245#M108842</link>
      <description>&lt;P&gt;of the 12k observations in total, with the constraints i put on the data with If statements i was expecting about 250 observations to be read by SAS.&lt;/P&gt;&lt;P&gt;I have five species, and i used an If statement to constrain the Sort to only one species in the example. When i shift that If statement to other species, they also return incorrect numbers of observations.&lt;/P&gt;</description>
      <pubDate>Wed, 14 Feb 2018 17:45:01 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Proc-IMPORT-won-t-read-data-from-excel-file/m-p/437245#M108842</guid>
      <dc:creator>AaronJ</dc:creator>
      <dc:date>2018-02-14T17:45:01Z</dc:date>
    </item>
    <item>
      <title>Re: Proc IMPORT won't read data from excel file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Proc-IMPORT-won-t-read-data-from-excel-file/m-p/437248#M108843</link>
      <description>&lt;P&gt;So your problem is with the IF statements not your import.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I would verify that the data is first being read in correctly and check how you're filtering.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Remember when filtering on character variables they are case sensitive.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Also, your log shows code that's different from what you posted, so what exactly is the code you're having issues with?&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;And can you post sample data? If not, run a PROC FREQ or MEANS on your data sets to check that it's correct and you're not overlooking something.&lt;/P&gt;</description>
      <pubDate>Wed, 14 Feb 2018 17:51:53 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Proc-IMPORT-won-t-read-data-from-excel-file/m-p/437248#M108843</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2018-02-14T17:51:53Z</dc:date>
    </item>
    <item>
      <title>Re: Proc IMPORT won't read data from excel file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Proc-IMPORT-won-t-read-data-from-excel-file/m-p/437375#M108882</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/97352"&gt;@AaronJ&lt;/a&gt; wrote:&lt;BR /&gt;yes, i am aware of that. and there are still 270 lines of data with numbers in them for each of the variables that SAS is not reading.&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Are you basing the above statement from looking at the data in the original Excel files?&lt;/P&gt;
&lt;P&gt;You may be thinking you have species values=1 or measurement&amp;nbsp;values =2 that are actually 1.01 or .99 (for species) or 2.01 or 1.99 because the display in Excel was set to no decimals.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You might want to print some of those records you think should be included from the IMPORT set to show the values of measurement, gld, dbh and height.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;It also helps to be consistent: Original post:&lt;/P&gt;
&lt;PRE&gt;if Measurement=2;
if GLD&amp;gt;0;
if DBH&amp;gt;0;
if Height&amp;gt;0;&lt;/PRE&gt;
&lt;P&gt;in the longer code example:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;74 if Species=1;
75 if Measurement=2;
76 if GLD&amp;gt;0.01;
77 if DBH&amp;gt;0.01;
78 if Height&amp;gt;0.01;&lt;/PRE&gt;
&lt;P&gt;which is more restrictive than with the addition of Species and increasing the limits of the last three variables.&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;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;BTW I notice you have code like this:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;DIV class="sasSource"&gt;85 /*proc univariate Normal Plot data=&lt;FONT color="#ff0000"&gt;Trees&lt;/FONT&gt;;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;86 var GLD DBH Height;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;87 by Tree Measurement;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;88 Histogram GLD DBH Height/Normal;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;89 QQPLOT GLD DBH Height;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;90 output out=&lt;FONT color="#ff0000"&gt;Trees&lt;/FONT&gt;;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;91 run;*/&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasSource"&gt;The first time you run this code you will replace your input set if that is actually executed. You need to be very aware of using that type of code in longer programs.&lt;/DIV&gt;</description>
      <pubDate>Wed, 14 Feb 2018 23:18:47 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Proc-IMPORT-won-t-read-data-from-excel-file/m-p/437375#M108882</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2018-02-14T23:18:47Z</dc:date>
    </item>
    <item>
      <title>Re: Proc IMPORT won't read data from excel file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Proc-IMPORT-won-t-read-data-from-excel-file/m-p/437699#M109031</link>
      <description>&lt;P&gt;Thanks for all the input everyone. I found my mistake: i didn't realize that the chain of IF&amp;nbsp;statements was an implicit AND. Many of my data didn't have BDH values so the program i wrote was excluding them. When i removed the IF statement for DBH, SAS found all the data that i was expecting.&lt;/P&gt;&lt;P&gt;Thanks again.&lt;/P&gt;</description>
      <pubDate>Thu, 15 Feb 2018 17:23:23 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Proc-IMPORT-won-t-read-data-from-excel-file/m-p/437699#M109031</guid>
      <dc:creator>AaronJ</dc:creator>
      <dc:date>2018-02-15T17:23:23Z</dc:date>
    </item>
    <item>
      <title>Re: Proc IMPORT won't read data from excel file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Proc-IMPORT-won-t-read-data-from-excel-file/m-p/437711#M109038</link>
      <description>Actually it’s an implicit OR, not AND when you likely wanted an AND. This may seem pedantic but it’s an important differentiation.</description>
      <pubDate>Thu, 15 Feb 2018 17:44:58 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Proc-IMPORT-won-t-read-data-from-excel-file/m-p/437711#M109038</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2018-02-15T17:44:58Z</dc:date>
    </item>
  </channel>
</rss>

