Q1.all the depts which has more then 10 empls?
Q2.all the dept which does not have any emply?
Q3 all the emp which does not have any dept?
Q4 get all the emply detais with the dept details it dept is
exit otherwise any emp details?
Q5 how to debugg the dynamic sql and packages?
Answer Posted / girija shankar dash
ANS-2:
SELECT department_id,COUNT(employee_id) AS "NO. OF EMPLOYEES"
FROM employees
GROUP BY department_id
HAVING COUNT(employee_id) = 0;
DEPARTMENT_ID NO. OF EMPLOYEES
201 0
311 0
Is This Answer Correct ? | 3 Yes | 2 No |
Post New Answer View All Answers
Explain dml and ddl?
How many joins can you have in sql?
Which command is used to call a stored procedure?
What is the difference between nested table and varray?
what are the nonstandard string types? : Sql dba
What is a design view?
C. Normalize the following data up to the 3rd Normal form. Create the tables and insert the data given. Emp_ID Name Dept_Name Salary Course_Title Date_Completed 100 Adam Marketing 48,000 SPSS 6/19/2008 Surveys 10/7/2008 140 Bob Accounting 52,000 Tax Acc 12/8/2008 110 Cathy IT SQL Server 1/12/2008 C# 4/22/2008 190 Dan Finance 150 Emily Marketing 55,000 SPSS 6/16/2008 42,000 Analysis 8/12/2008 Queries 1. Find all Names who have completed the SPSS Course. 2. Find employee with max salary. 3. Find employee with 2nd max salary. 4. Find all employees in Dept “Marketing”. 5. Find all the employees who have taken more than 2 courses. 6. Find all the employees who have completed the courses before month of September.
what are all the different normalizations? : Sql dba
What is the purpose of using pl/sql?
What is primary key secondary key alternate key candidate key?
How to combine two stored procedures in sql?
Why do we use sql constraints?
Are views faster than queries?
Can unique keys be null?
What is sql resultset?