BookmarkSubscribeRSS Feed
Petersas
Calcite | Level 5

Hi,

I have a DB2 query in mainframe which is pulling data from tables. I'm currently trying to run the same DB2 query in SAS program and want to fetch the data from the tables. I'm new to SAS-DB2. Please provide me pointers on how to achieve this.

I tried the following:

PROC SQL;
CONNECT TO DB2 (SSID=DBQ2);
%PUT &SQLXMSG;
CREATE TABLE SASDS AS
SELECT * FROM CONNECTION TO DB2
(
SQL QUERY
);
%PUT &SQLXMSG;
DISCONNECT FROM DB2;
%PUT &SQLXMSG;

 

but was getting error.

ERROR: Unable to load the DB2 Call Attach Facility.  
ERROR: A Connection to the DB2 DBMS is not currently supported, or IS not installed at your site.

PROC SQL set option NOEXEC
NOTE: Statement not executed due to NOEXEC option.

 

Please advise.

 

Thanks in Advance!!!

 

2 REPLIES 2
LinusH
Tourmaline | Level 20

Seems that something is lacking in the configuration.

Where is your SAS program executing?

What kind of DB2 client are your using (native, ODBC)?

Do you have the necessary license?

Does anybody at your site managed to connect from SAS to this DB2 earlier?

Versions (SAS, DB2)...?

 

http://support.sas.com/techsup/notes/v8/1/010.html

Data never sleeps
Petersas
Calcite | Level 5

Hi LinusH,

 

Where is your SAS program executing?   -- SAS is working on Mainframe.

What kind of DB2 client are your using (native, ODBC)? -- SAS SQL PROC

Do you have the necessary license? --

---Base Product                         
---SAS/ACCESS Interface to DB2          
---SAS/ACCESS Interface to IMS-DL/I 

Does anybody at your site managed to connect from SAS to this DB2 earlier? 

Versions (SAS, DB2)...? -- SAS 9.1.3

 

Thanks.

 

 

sas-innovate-wordmark-2025-midnight.png

Register Today!

Join us for SAS Innovate 2025, our biggest and most exciting global event of the year, in Orlando, FL, from May 6-9. Sign up by March 14 for just $795.


Register now!

What is Bayesian Analysis?

Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.

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
  • 2 replies
  • 1768 views
  • 0 likes
  • 2 in conversation