LISTSERV at the University of Georgia
Menubar Imagemap
Home Browse Manage Request Manuals Register
Previous messageNext messagePrevious in topicNext in topicPrevious by same authorNext by same authorPrevious page (October 2002, week 3)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Thu, 17 Oct 2002 15:20:38 -0700
Reply-To:     "William W. Viergever" <wwvierg@ATTGLOBAL.NET>
Sender:       "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:         "William W. Viergever" <wwvierg@ATTGLOBAL.NET>
Subject:      Re: Reading Excel into SAS
Comments: To: "Smith, Curtis, Mr, DCAA" <Curtis.Smith@DCAA.MIL>
In-Reply-To:  <FA0431E7B94BCF4196CE1D5334CB2F53010FAD40@dcaamemx4.dcaa.mi l>
Content-Type: text/plain; charset="us-ascii"; format=flowed

At 05:03 PM 10/17/2002 -0500, Smith, Curtis, Mr, DCAA wrote:

>The Excel file must be open in Excel. Are you closing the Excel file >after reading it the first time?

If not that, sometimes (I forget what vers of what) you need to leave off the path (i.e., the G:\IMMUNEX\ part).

HTH (hope this helps)

Out

>-----Original Message----- >From: Jeff Magouirk [mailto:magouirkj@NJC.ORG] >Sent: Thursday, October 17, 2002 2:49 PM >To: SAS-L@LISTSERV.UGA.EDU >Subject: Reading Excel into SAS > > >Dear SAS-L, > >I am having a problem with reading an Excel spreadsheet into SAS. SAS is >saying the physical file does not exist. I have quoted the filename >statement with single quotes and double quotes, Each has worked once, >but when I run the code again, from the log I recieve the following >message. > > >1845 filename four dde 'Excel|G:\IMMUNEX\[3JAG02.xls]visit >4!R5C3:R25C18'; 1846 >1847 Data work.jag04; >1848 infile four missover; >1849 format date_iss mmddyy8.; >1850 input Day $ Day_of_week $ >1851 Dose_m puffs_m wheez_m chest_m breath_m Cough_m peak_flow_m >inhaler_m > >1852 wheez_e chest_e breath_e Cough_e peak_flow_e inhaler_e; >1853 d1=scan(Day_of_week,2,"/"); >1854 m1=substr(Day_of_week,1,2); >1855 m=compress(m1,"/"); >1856 d=compress(d1,"/"); >1857 y1=substr(Day_of_week,7,2); >1858 y=2000+y1; >1859 date_iss=mdy(m,d,y); >1860 id="3JAG02"; >1861 drop d1 m1 m d y1 y day day_of_week; >1862 if date_iss =. then delete; >1863 run; > >NOTE: Character values have been converted to numeric values at the >places given by: (Line):(Column). > 1858:11 1859:17 1859:19 >ERROR: Physical file does not exist, Excel|G:\IMMUNEX\[3JAG02.xls]visit >4! R5C3:R25C18. >NOTE: The SAS System stopped processing this step because of errors. >WARNING: The data set WORK.JAG04 may be incomplete. When this step was >stopped there were 0 observations and 16 variables. > >Thanks in advance for the help. > >Sincerely, > >Jeff Magouirk

------------------------------------------------------------ William W. Viergever Voice : (916) 483-8398 Viergever & Associates Fax : (916) 486-1488 Sacramento, CA 95825 E-mail : wwvierg@attglobal.net ------------------------------------------------------------


Back to: Top of message | Previous page | Main SAS-L page