libname perm 'C:\Users\Eden\OneDrive\Documents'; data perm.fungal; infile 'C:\Users\Eden\OneDrive\Documents\fungal.txt' firstobs=2 input patno treat $ age sex $ severity clears; run;
This, below is the syntax I'm getting...
1 libname perm 'C:\Users\Eden\OneDrive\Documents'; NOTE: Libref PERM was successfully assigned as follows: Engine: V9 Physical Name: C:\Users\Eden\OneDrive\Documents 2 data perm.fungal; 3 infile 'C:\Users\Eden\OneDrive\Documents\fungal.txt' firstobs=2 4 input patno treat $ age sex $ severity clears; ----- 23 ERROR 23-2: Invalid option name INPUT. 4 ! input patno treat $ age sex $ severity clears; ----- 23 ERROR 23-2: Invalid option name PATNO. 4 ! input patno treat $ age sex $ severity clears; ----- 23 ERROR 23-2: Invalid option name TREAT. 4 ! input patno treat $ age sex $ severity clears; - - 23 23 ERROR 23-2: Invalid option name $. 4 ! input patno treat $ age sex $ severity clears; --- 23 ERROR 23-2: Invalid option name AGE. 4 ! input patno treat $ age sex $ severity clears; --- 23 ERROR 23-2: Invalid option name SEX. 4 ! input patno treat $ age sex $ severity clears; -------- 23 ERROR 23-2: Invalid option name SEVERITY. 4 ! input patno treat $ age sex $ severity clears; ------ 23 ERROR 23-2: Invalid option name CLEARS. 5 run; NOTE: The SAS System stopped processing this step because of errors. WARNING: The data set PERM.FUNGAL may be incomplete. When this step was stopped there were 0 observations and 0 variables. WARNING: Data set PERM.FUNGAL was not replaced because this step was stopped. NOTE: DATA statement used (Total process time): real time 0.07 seconds cpu time 0.01 seconds
Help would be appreciated
@scottyniven wrote:
Hi guy, thanks... however now when I put the semicolon Im still having this issue physical file does not exist when I know its in my dcuments...
SHOW the log. Copy the text from the log, open a text box on the forum with the </> icon and paste the text.
That we we know what you actually submitted. Maybe you "put the semicolon" in the wrong place. Maybe you mistyped an used a colon.
Another thing that you really want to verify is that the file name is correct. If you misspell the name or extension then the file does not exist because you gave SAS the wrong name. Using Windows explorer I often highlight the file and copy the text as I am too lazy to retype if not needed, especially the paths.
This is the dataset I am attempting to import. I believe that I have put the $'s in the right place though...
Did you not see the answer in your previous post? Your INFILE statement is missing a semicolon.
If you get such "weird" errors where SAS calls a statement or function something else (like option here) always investigate if there is a semicolon missing or something wrong with quoting.
Hi guy, thanks... however now when I put the semicolon Im still having this issue physical file does not exist when I know its in my dcuments...
The successful libname statement tells us that the path to the Documents folder exists and is valid.
If you get a file does not exist error then you've either misspelled the file name or it's in a different folder or (unlikely) the user under which you execute SAS doesn't have sufficient access so SAS can't "see" the file.
How would I go about giving permission to sas to access the file?
@scottyniven wrote:
Hi guy, thanks... however now when I put the semicolon Im still having this issue physical file does not exist when I know its in my dcuments...
SHOW the log. Copy the text from the log, open a text box on the forum with the </> icon and paste the text.
That we we know what you actually submitted. Maybe you "put the semicolon" in the wrong place. Maybe you mistyped an used a colon.
Another thing that you really want to verify is that the file name is correct. If you misspell the name or extension then the file does not exist because you gave SAS the wrong name. Using Windows explorer I often highlight the file and copy the text as I am too lazy to retype if not needed, especially the paths.
Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 16. Read more here about why you should contribute and what is in it for you!
Follow along as SAS’ Robert Blanchard explains three aspects of autotuning in a deep learning context: globalized search, localized search and an in parallel method using SAS.
Find more tutorials on the SAS Users YouTube channel.