BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
thebugslayer
Fluorite | Level 6
OPTIONS NONOTES NOSTIMER NOSOURCE NOSYNTAXCHECK;
75
76 libname seacoastlib odbc dsn="seacoast" user="myuser" pass="mypassword";
ERROR: seacoastlib is not a valid SAS name.
ERROR: Error in the LIBNAME statement.
77
78 OPTIONS NONOTES NOSTIMER NOSOURCE NOSYNTAXCHECK;
91
 

 

Running the statement below to connect to a SQL Server database through DSN and I get error "ERROR: seacoastlib is not a valid SAS name:

libname seacoastlib odbc dsn="seacoast" user="myuser" pass="mypassword";

 

I have another statement, almost the same, to a different DSN, all in the same ODBC.INI file; the only difference is that the other statement includes a schema.

libname etllib odbc dsn="etl" user="myuser" pass="mypassword" schema="myschema";

PS: this statement that executes resides in a file created a long time ago. Maybe some variable created that reside in the system somewhere. The one that fails was created today.

 

I have even tried 

caslib seacoastlib datasource="seacoast" user="myuser" pass="mypassword" 

What am I missing?

1 ACCEPTED SOLUTION

Accepted Solutions
ballardw
Super User

SAS Library names are limited to 8 characters;

seacoastlib is 11 characters

make it shorter

seacoast would be acceptable.

View solution in original post

3 REPLIES 3
ballardw
Super User

SAS Library names are limited to 8 characters;

seacoastlib is 11 characters

make it shorter

seacoast would be acceptable.

thebugslayer
Fluorite | Level 6
Thank you so much!
SAS should take care not to use non-compliant names in online examples.
ballardw
Super User

Please post the link to the online example you reference that used a non-compliant name.

sas-innovate-2024.png

Available on demand!

Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.

 

Register now!

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
  • 3 replies
  • 638 views
  • 1 like
  • 2 in conversation