You are on page 1of 5

ICT450

SQL
LAB EXERCISE
28th April 2019
D1CS2493A

Your Name: NUR ZULHARNI AISHA BINTI ZULKIFLI


Matric Card No: 2017598351

QUESTION 1
Display the employee number, last name, salary, education level and hire date for all female
employees. Sort your output according to education level in descending order

1|Page
QUESTION 2
Display the date of birth for all female employees together with their first names, sex, hire
dates, bonus and department number. Sequence the result by hire date ascendingly.

QUESTION 3
Produce a report to show the details of male employees (last name, sex, salary, hire date,
and department number) who are hired in 2006 and their salaries are between $30000 and
$60000. The list should be ordered by last name.

2|Page
QUESTION 4
Display the department number and manager number for all departments to which the
manager has been assigned. Exclude from your answer the departments that do not have
managers.

QUESTION 5
Produce a report that lists employees’ first names, sex, salary, commission and department
names for all employees who earn salary greater than $60,000.00. Sort the output according
to first name within the department name.

3|Page
QUESTION 6
List the department number, department name and the first name and last name of its
manager. Sort the output according to first name in descending order.

QUESTION 7
For each department, show the department number and calculate the total employees, total
salaries and total bonus of its employees. Sort your result according to department number.

4|Page
QUESTION 8
Determine the total salary, average bonus and total commission for all female employees.

QUESTION 9
Calculate the total number of employees for every department that starts with letter D and E.
Show only the department that has greater or equal to 5 employees.

QUESTION 10
Display the first name, last name, sex and salary for the employee who earns the lowest
salary

5|Page

You might also like