Chapter Contents |
Previous |
Next |
SAS/ACCESS Software for Relational Databases: Reference |
For a complete description of the PROC SQL statements, see SQL Procedure Pass-Through Facility Statements. The following section describes the SYBASE-specific arguments that you use in the CONNECT statement.
Arguments to Connect to SYBASE |
The CONNECT statement is optional. If omitted, the default values for all of the connection arguments are used.
CONNECT TO SYBASE <AS alias> <(connection-arguments)>; |
Connection arguments for SYBASE are all case-sensitive. They are passed to SYBASE exactly as you type them. See Case Sensitivity in SYBASE for more information.
PASSWORD= can also be specified with the SYBPW= alias.
DATABASE= can also be specified with the DB= alias.
If you omit this statement, the default action for your operating system occurs. INTERFACE= is not used in some operating environments. Contact your DBA to determine whether it applies to your operating environment.
If you omit this statement, no data is written to the buffer.
Pass-Through Example |
The following example retrieves a subset of rows from the SYBASE INVOICE table. Because the WHERE clause is specified in the DBMS query (the inner SELECT statement), the DBMS processes the WHERE expression and returns a subset of rows to the SAS System.
proc sql; connect to sybase(server=SERVER1 database=INVENTORY user=testuser password=testpass); %put &sqlxmsg; select * from connection to sybase (select * from INVOICE where BILLEDBY=457232); %put &sqlxmsg;
Note: The SELECT statement
that is enclosed in parentheses is sent directly to the database and therefore
must be specified using valid database variable names and syntax.
Chapter Contents |
Previous |
Next |
Top of Page |
Copyright 1999 by SAS Institute Inc., Cary, NC, USA. All rights reserved.