Produces an intermediate result table by applying the search-condition to each group of R, where R is the result of the previous clause. If that clause is not GROUP BY, all rows of R are considered as one group. The result table contains those groups of R for which the search condition is true.
The search-condition describes a search condition that conforms to the following rules:
A group of R to which the search condition is applied supplies the argument for each function in the search condition, except for any function whose argument is a correlated reference.
If the search condition contains a subquery, the subquery can be thought of as being executed each time the search condition is applied to a group of R, and the results used in applying the search condition. In actuality, the subquery is executed for each group only if it contains a correlated reference.
A correlated reference to a group of R must either identify a grouping column or be contained within a function.
The HAVING clause must not be used in:
|
Copyright © 2014 CA.
All rights reserved.
|
|