BookmarkSubscribeRSS Feed
Analysts12
Obsidian | Level 7
I have a sql library created in sas . The database team is able to view tables at db level , but in SAS EG , no tables are getting populated.
What to do ?
24 REPLIES 24
SASKiwi
PROC Star

How is the data library being created in SAS? Via a LIBNAME statement in code or is it being created in SAS metadata via SAS Management Console.

 

Does the library show in the EG Server List? If so what happens when you expand the library?

Analysts12
Obsidian | Level 7
It is created via management console .
Yes, the library is visible on SAS EG but tables are not getting populated there as well.
SASKiwi
PROC Star

Try adding this to your SMC data library definition:

screenshot13.jpg

This should ensure SQL library tables get listed.

Analysts12
Obsidian | Level 7
that didn't work ...
😞
DavidHD
SAS Employee

What happens if you submit the libname statement in code from EG? Do the tables then show up?

Analysts12
Obsidian | Level 7

I get the following error: when I submit via code 

ERROR: CLI error trying to establish connection: [DataDirect][ODBC lib] Data source name not found and no default driver specified
NOTE: Statements not processed because of errors noted above.

SASKiwi
PROC Star

There is probably something wrong with the data library definition then. Try @DavidHD 's suggestion to trial and get it working. For the SQL LIBNAME to work you need to define the server, database and schema.

Analysts12
Obsidian | Level 7

Ok.. I tried via code as well, it didn't work.

 

However, the database team suggested that the user credentials are not created via Active directory, so maybe that is the reason, its not linking properly

DavidHD
SAS Employee
  1. Check that you can reach the DB Server from the SAS Server (e.g. ping it) - if this doesn't work check with the Firewall/DNS-Team.
  2. Validate your user credentials with the DB Team
  3. Submit via code libname statement with this works move the SMC
  4. If you get errors search for that error online and fix as appropriate - you might need to get in contact with the DB admins again
Analysts12
Obsidian | Level 7

This is the error I receive via code:
ERROR: CLI error trying to establish connection: [DataDirect][ODBC lib] Data source name not found and no default driver specified

SASKiwi
PROC Star

Please post the SAS log of your LIBNAME statement. Just saying it didn't work doesn't help us to see what might be going wrong.

Ksharp
Super User
Check SCHEMA= option of LIBNAME .
Sajid01
Meteorite | Level 14

Hello @Analysts12 
The information you provided in insufficient. It will lead to many questions. 
1.From your other posts, I presume the SAS is installed on Linux Server and the user is accessing the server using EG.

2.What is your database ? Have you installed the database client / odbc drivers  on the App server? In a corporate environment this is typically done by Database Administrators.

3.If the answers to the above questions is yes, can you access the database using libname statement?

 (You have said in an earlier answer that library is visible but not answered about the libname statement to the post by @DavidHD )

4. If the answer to the above is no, then go back to step 2. If it is yes proceed to the next step.

5.Please read this https://documentation.sas.com/doc/en/bicdc/9.4/bidsag/titlepage.htm If you name your database somebody will be able to provide a more relevant answer..


 

Sajid01
Meteorite | Level 14

"I get the following error: when I submit via code 
ERROR: CLI error trying to establish connection: [DataDirect][ODBC lib] Data source name not found and no default driver specified
NOTE: Statements not processed because of errors noted above."

 

There is something wrong with the way connections have been setup.
Have the odbc drivers installed ?
Please check the odbc.ini (on unix)/ODBC Administrator on windows.
I had mentioned this in my last post (item no 2).

suga badge.PNGThe SAS Users Group for Administrators (SUGA) is open to all SAS administrators and architects who install, update, manage or maintain a SAS deployment. 

Join SUGA 

Get Started with SAS Information Catalog in SAS Viya

SAS technical trainer Erin Winters shows you how to explore assets, create new data discovery agents, schedule data discovery agents, and much more.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 24 replies
  • 4858 views
  • 1 like
  • 5 in conversation