|Oracle8i SQL Reference
Release 2 (8.1.6)
Functions, 117 of 121
For information on syntax and semantics, see "Analytic Functions".
VAR_SAMP returns the sample variance of a set of numbers after discarding the nulls in this set. You can use it as both an aggregate and analytic function.
The expr is a number expression, and the function returns a value of type
NUMBER. If the function is applied to an empty set, it returns null. The function makes the following calculation:
This function is similar to
VARIANCE, except that given an input set of one element,
VARIANCE returns 0 and
VAR_SAMP returns null.
The following example returns the sample variance of the salaries in the
See the example at "VAR_POP".