Select clause

The select clause in the query function identifies the object properties that are to be returned by a query.

The select clause describes the query result. It specifies a list of names that identify the object properties (columns of the result) to return. Its syntax is the same as an SQL select clause; use commas to separate parts of the clause. Each part of the clause must specify a property from one of the predefined views. The columns returned in the QueryResultSet object appear in the same order as the properties specified in the select clause.

The select clause does not support SQL aggregation functions, such as AVG(), SUM(), MIN(), or MAX().

To select properties of name-value pairs, such as custom properties, add a one-digit suffix to the view name.

Examples of select clauses

If an error occurs during the processing of the select clause, a QueryUnknownTable or a QueryUnknownColumn exception is thrown with the name of the property that is not recognized as a table or column name.


Terms of use |

Last updated: Tue Feb 21 17:31:25 2006

(c) Copyright IBM Corporation 2005.
This information center is powered by Eclipse technology (http://www.eclipse.org)