When you select Generated query, data is extracted from an ODBC data source by using an SQL SELECT statement that is constructed by IBM® InfoSphere™ DataStage®. SQL SELECT statements have the following syntax:
SELECT clause FROM clause
[WHERE clause]
[GROUP BY clause]
[HAVING clause]
[ORDER BY clause];
After you specify the tables to use and the columns to be output from the ODBC stage, the SQL SELECT statement is automatically constructed and can be viewed by clicking the View SQL tab on the Outputs page.
For example, if you extract the columns Name, Address, and Phone from a table called Table1, the SQL statement that is displayed on the View SQL tab is:
SELECT Name, Address, Phone FROM Table1;
The SELECT and FROM clauses are the minimum clauses that are required. These clauses are automatically generated by InfoSphere DataStage. However, you can use any of these SQL SELECT clauses:
If you want to use the additional SQL SELECT clauses, you must specify them on the Selection tab on the Outputs page. The Selection tab is divided into two parts:
This topic is also in the IBM InfoSphere DataStage and QualityStage Connectivity Guide for ODBC.
