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

Hi SAS Frens,

 

When I submit the code below it works fine (SAS 9.4 Grid on Windows environment) but when I schedule the job to run (SAS Scheduling Server) it fails with the below error. My guess is that the Server does not have the SAS/ACCESS interface. Would Explicit SQL Pass through be any help?

 

 

libname oraRXI oracle user=XXXXX pw="XXXXX"
         schema=RXI path="(DESCRIPTION= (ADDRESS= (PROTOCOL=TCP)(HOST=XXX.com)(PORT=XXXX)) (CONNECT_DATA=(SERVICE_NAME=XXXX.com)))";


proc sql;
create table want as select * from have;
quit;

 

ERROR: The SAS/ACCESS Interface to ORACLE cannot be loaded.

ERROR: Image SASORA found but not loadable..

ERROR: in the LIBNAME statement

ERROR: Libref ORARXI is not assigned.

 

1 ACCEPTED SOLUTION

Accepted Solutions
ChrisHemedinger
Community Manager

I'd check the license/install in your batch job by including proc product_status; run; and reviewing that log.

 

If SAS/ACCESS to Oracle is not available, then explicit passthrough will not work either. If it is licensed/installed, then your SAS environment still needs to know where your Oracle client is, the TNSNAMES.ora file, etc. These are usually controlled by environment variables and an Oracle or SAS admin can advise.

 

Just went through this myself and added these variables to my shell script:

 

export ORACLE_HOME=[path]/oracle/12.2.0.1
export LD_LIBRARY_PATH=[path]/oracle/12.2.0.1/lib
export TNS_ADMIN=[path]/admin
Learn from the Experts! Check out the huge catalog of free sessions in the Ask the Expert webinar series.

View solution in original post

3 REPLIES 3
ChrisHemedinger
Community Manager

I'd check the license/install in your batch job by including proc product_status; run; and reviewing that log.

 

If SAS/ACCESS to Oracle is not available, then explicit passthrough will not work either. If it is licensed/installed, then your SAS environment still needs to know where your Oracle client is, the TNSNAMES.ora file, etc. These are usually controlled by environment variables and an Oracle or SAS admin can advise.

 

Just went through this myself and added these variables to my shell script:

 

export ORACLE_HOME=[path]/oracle/12.2.0.1
export LD_LIBRARY_PATH=[path]/oracle/12.2.0.1/lib
export TNS_ADMIN=[path]/admin
Learn from the Experts! Check out the huge catalog of free sessions in the Ask the Expert webinar series.
SAShole
Pyrite | Level 9
I confirmed that SAS/ACCESS Interface is available and have reached out to the SAS Admins about pointing SAS to the Oracle DB. Thank you for the info about TNSNAMES.ora it was helpful.
ChrisHemedinger
Community Manager

In your SAS programs you can check the current values of these environment variables to report them in the SAS log:

 

%put %sysget(ORACLE_HOME);
%put %sysget(TNS_ADMIN);
%put %sysget(LD_LIBRARY_PATH);
Learn from the Experts! Check out the huge catalog of free sessions in the Ask the Expert webinar series.

SAS Innovate 2025: Save the Date

 SAS Innovate 2025 is scheduled for May 6-9 in Orlando, FL. Sign up to be first to learn about the agenda and registration!

Save the date!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 3 replies
  • 974 views
  • 4 likes
  • 2 in conversation