query to retrive the employees whose sal is greater than avg
sal
Answer Posted / viren
since we are using aggregate function AVG, we have to use
GROUP BY, HAVING clause.
select empName, avg(sal) from employees group by sal having
sal > avg(sal) order by empName;
| Is This Answer Correct ? | 4 Yes | 12 No |
Post New Answer View All Answers
What does select count (*) mean in sql?
what is a database lock ? : Sql dba
What are literals in sql server?
What are the topics in pl sql?
What is procedure in pl sql?
What are some emotional triggers?
what is data control language? : Sql dba
Mention what problem one might face while writing log information to a data-base table in pl/sql?
How do I remove all records from a table?
how to enter binary numbers in sql statements? : Sql dba
Does sql support programming?
what is a database transaction? : Sql dba
Explain the working of primary key?
What is a natural join sql?
What are expressions?