write a query to find out the no. of employees whose age is
less than 25 and max of salary for the employees belonging
to a particular department is less than 20000

Answer Posted / nitin umale

SELECT department_id, COUNT(employee_id), MAX(salary)
FROM employees
WHERE MONTHS_BETWEEN(hire_date, SYSDATE) < 25*12
GROUP BY department_id
HAVING MAX(salary) < 20000;

Is This Answer Correct ?    3 Yes 6 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Which one is faster ienumerable or iqueryable?

570


What happens when a trigger is associated to a view?

593


Can dml statements be used in pl/sql?

674


What is dml and ddl?

609


What is the trigger in sql?

621






What is sql*loader and what is it used for? : aql loader

704


How do I create a sql database?

620


What is a sql*loader control file?

712


What is the use of triggers?

631


what is a scheduled jobs or what is a scheduled tasks? : Sql dba

640


What is nvarchar max in sql?

671


What does select top 1 do in sql?

625


How does postgresql compare to oracle/db2/ms sql server/informix?

670


What is the difference between null value, zero, and blank space?

649


What is mutating trigger?

679