Invoking Direct SQL Passthru

To invoke the Direct SQL Passthru facility, you must establish the target RDBMS in either of the following two ways:

In this section:

Invoking Automatic Passthru

How to:

Issue the SET SQLENGINE Command


Top of page

Invoking Automatic Passthru

If you do not establish a target RDBMS, the SQL Translator processes the request. However, the Translator will invoke Automatic Passthru (APT) when the SQL submitted contains valid syntax for the RDBMS being accessed.

As a result, the SQL code will not be processed by FOCUS, but instead will be sent directly to the RDBMS. Column names displayed in the report will be the RDBMS table's column names, which correspond with the Master File's ALIAS values. If this behavior is not desirable, you can disable Automatic Passthru for the request by issuing the SET APT=OFF; command in the SQL query:

SQL
SET APT = OFF;
sql statement
END

Top of page

Syntax: How to Issue the SET SQLENGINE Command

SET SQLENGINE = sqlengine

where:

sqlengine
Indicates the target RDBMS. Valid values are as follows:

OFF
Indicates that unless the request specifies a target RDBMS, the SQL Translator will process the request. OFF is the default setting.

DB2
Indicates the DB2 RDBMS.

SQLDS
Indicates the DB2 for VM RDBMS.

SQLDBC
Indicates the Teradata RDBMS.

SQLIDMS
Indicates the CA-IDMS/SQL RDBMS.

SQLORA
Indicates the Oracle RDBMS.

You can change the SQLENGINE setting at any point in your FOCUS session.


Information Builders