ODBC Server Reference Manual
Transact-SQL Language
HP NonStop ODBC Server Reference Manual—429151-002
4-88
HAVING Clause
column-name
is the name of a column from one of the tables in the FROM clause.
expression
is not supported. In the NonStop ODBC Server, expressions in the
aggregate-free-expression cause an error message.
HAVING Clause
The HAVING clause of the SELECT statement sets conditions for the GROUP BY
clause and has the following syntax:
Search conditions are described under Language Elements on page 4-5.
ORDER BY Clause
The ORDER BY clause of the SELECT statement specifies the order in which to sort
the rows of the result table and has the following syntax:
table-reference.column-name
is the name of a column from one of the tables or views in the FROM clause. The
column name can be qualified with the database name and owner name.
select-list-number
is a number representing the position of the item in the select list. The
select-list can be an asterisk (*).
expression
is not supported. An error message is generated.
HAVING search-condition
ORDER BY sort-spec [ , sort-spec ] ...
sort-spec is:
{ [table-reference.]column-name } [ ASC ]
{ } [ DESC ]
{ select-list-number }
{ }
{ expression }
table-reference is:
[ [database.]owner. ] { table-name }
{ view-name }