BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
bhufman
Calcite | Level 5

Hi everyone, 

Below is the Libname statements I am using, I keep getting an Error on Libname "HypeResults." Here is a copy of the Libname and the log:

 

%LET CourseRoot = /folders/myfolders/My Folders/BIOS6680;
LIBNAME HypTabs "/folders/myfolders/My Folders/BIOS6680/Cancer RCT/Data/3_Tabulations";
LIBNAME Hypan1 "/folders/myfolders/My Folders/BIOS6680/Cancer RCT/Data/4_Analysis";
Libname HypResults "/folders/myfolders/My Folders/BIOS6680/Cancer RCT/Data/5_Results";
/* Enter additional LIBNAME statements */
/* Enter any necessary options in an OPTIONS statement*/
OPTIONS FMTSEARCH= (Hyptabs.hypformats WORK LIBRARY)
NOFMTERR;

 

 

1 OPTIONS NONOTES NOSTIMER NOSOURCE NOSYNTAXCHECK;
72
73 * Instructions:
74 1) Change the path in the %LET statement to the location of the BIOS 6680 course root folder
75 2) Submit the %LET and LIBNAME statements below *;
76 %LETCourseRoot = /folders/myfolders/My Folders/BIOS6680;
77 LIBNAME HypTabs"/folders/myfolders/My Folders/BIOS6680/Cancer RCT/Data/3_Tabulations";
NOTE: Libref HYPTABS was successfully assigned as follows:
Engine: V9
Physical Name: /folders/myfolders/My Folders/BIOS6680/Cancer RCT/Data/3_Tabulations
78 LIBNAME Hypan1 "/folders/myfolders/My Folders/BIOS6680/Cancer RCT/Data/4_Analysis";
NOTE: Libref HYPAN1 was successfully assigned as follows:
Engine: V9
Physical Name: /folders/myfolders/My Folders/BIOS6680/Cancer RCT/Data/4_Analysis
79 Libname HypResults "/folders/myfolders/My Folders/BIOS6680/Cancer RCT/Data/5_Results";
ERROR: HypResults is not a valid SAS name.
ERROR: Error in the LIBNAME statement.
80 /* Enter additional LIBNAME statements */
81 /* Enter any necessary options in an OPTIONS statement*/
82 OPTIONS FMTSEARCH= (Hyptabs.hypformats WORK LIBRARY)
83 NOFMTERR;
84
85
86 OPTIONS NONOTES NOSTIMER NOSOURCE NOSYNTAXCHECK;
98
 

Do you initially see anything wrong with my HypResults Libname?

1 ACCEPTED SOLUTION

Accepted Solutions
Allie_Haun
Fluorite | Level 6

Hi there! 

I believe this naming convention may be too long. Try "HypRslt" instead of HypResults

View solution in original post

5 REPLIES 5
Allie_Haun
Fluorite | Level 6

Hi there! 

I believe this naming convention may be too long. Try "HypRslt" instead of HypResults

ballardw
Super User
Libname HypResults "/folders/myfolders/My Folders/BIOS6680/Cancer RCT/Data/5_Results";

Libnames are always limited to a maximum of 8 characters, the first character must be a letter or the _ character, others letter, digit or _. No other characters allowed.

AnnaWoolery
Calcite | Level 5

Hi Breanna,

 

Another issue you may be having is that your LIBNAME statements include "Cancer RCT" in the location route. I believe this should be "Hypertension Study" instead. Hope this also helps 🙂

 

LIBNAME HypTabs "/folders/myfolders/My Folders/BIOS6680/Cancer RCT/Data/3_Tabulations";
LIBNAME Hypan1 "/folders/myfolders/My Folders/BIOS6680/Cancer RCT/Data/4_Analysis";
Libname HypResults "/folders/myfolders/My Folders/BIOS6680/Cancer RCT/Data/5_Results";

Rohan_Garg4
Calcite | Level 5

Hey BHufman,

 

Regarding your libname error, I am pretty sure the libname statement can only be 8 character long. So would need to reduce it HypRslts at the max in order have it be valid.

bfreeman0402
Calcite | Level 5

Hi Bre!

 

I was having a really similar issue when working with the HypAnalysis1 data set for homework. I think your LIBNAME statement might be too long (I used HypRes)! Also, im not sure what version of SAS you may be using but I had a ton of issues with SAS OnDemand when I was using it (raw data wouldn't open, libraries weren't saving correctly, etc) and I can honestly say when I downloaded university edition I had way less issues like this! Hope this helps 🙂

 

Best,

Brandon 

SAS Innovate 2025: Call for Content

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!

Submit your idea!

Mastering the WHERE Clause in PROC SQL

SAS' Charu Shankar shares her PROC SQL expertise by showing you how to master the WHERE clause using real winter weather data.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 5 replies
  • 2775 views
  • 0 likes
  • 6 in conversation