You are on page 1of 6

Laboratory 12

Database Management System

1. Write a query that will display clerks who were hired before and after the year 1998.
Laboratory 12

Database Management System

2. The HR department needs a report of employees who doesn’t earn commission. Show the
last name, salary and job id. Sort data by first name.

3. Create a report that produces the following for each employee:


<​employee  last  name>  was  hired  <hire  date>  with monthly salary 
of <salary​>.
Laboratory 12

Database Management System

4. Write a query that displays those employees who have no commission for ​every
department​.
Laboratory 12

Database Management System

5. Display each employee’s last name, hire date and salary of every department. Format the
dates to appear in the format similar to “Mon, 29​th​ Day of February, Two Thousand Sixteen”.
Laboratory 12

Database Management System

6. Write a SQL statement that display employees last name with the number of years and the
number of completed months that they have been employed. The employee who has been
employed the longest should appear at the top of the list.

7. Show those employees who have a last name ending with letter “D”,”A”,”I” or “S”.
Laboratory 12

Database Management System

8. Create a report that display all employees and indicate with word ​Regular or ​Irregular
​ se CASE expression in your statement.
whether they receive a commission.​ U

9. Create a query that will display the total number of employees for job id Sales Clerk, Sales
Representative, IT Programmer and Admin Assistant.

10. Display job id where manager is managing less than 3 employees.

You might also like