Which of the following way is correct to calculate variance of a column?

Options
- SELECT (salary)VARIANCE FROM employee;
- SELECT VARIANCE(salary) FROM employee;
- SELECT salary (VARIANCE) FROM employee;
- Both a and b


CORRECT ANSWER : SELECT VARIANCE(salary) FROM employee;

Discussion Board
VARIANCE

SELECT VARIANCE(salary) FROM employee; - This is a correct way to calculate variance of a column. VARIANCE returns the variance of expression. You can use it as an aggregate or analytic function. This function takes as an argument any numeric datatype or any non-numeric datatype that can be implicitly converted to a numeric datatype. The function returns the same datatype as the numeric datatype of the argument.

Prajakta Pandit 02-15-2017 01:03 AM

Write your comments


Enter the code shown above:

(Note: If you cannot read the numbers in the above image, reload the page to generate a new one.)


Advertisement