
263
CHAPTER
14
Accessing DBMS Data with the
Pass-Through Facility
About the Pass-Through Facility Sample Code
263
Retrieving DBMS Data with a Pass-Through Query
264
Combining a PROC SQL View with a SAS Data Set
266
Using a Pass-Through Query in a Subquery
267
About the Pass-Through Facility Sample Code
The examples in this section demonstrate how to use the Pass-Through Facility to
access and update DBMS data. The Pass-Through Facility enables you to read and
write data between SAS and a DBMS, however, it is recommended that you use the
LIBNAME statement to access your DBMS data more easily and directly.
To run these examples, complete the following steps:
1 Modify and submit the appropriate autoexec program for your DBMS interface:
DB2
db2auto.sas
Informix
infauto.sas
ODBC and Microsoft SQL Server
odbauto.sas
OLE DB
oleauto.sas
Oracle
oraauto.sas
SYBASE
sybauto.sas
Teradata
terauto.sas
Note: For sample code for Oracle Rdb, see the documentation for that
SAS/ACCESS interface .
2 Submit the SampData.sas program to create the DBMS tables and SAS data sets
that the sample code uses.
3 Submit the SampRun.sas program to run the samples.
These programs are available in the SAS Sample Library. If you need assistance
locating the Sample Library, contact your SAS support consultant. See “Descriptions of