Professional Documents
Culture Documents
LAB-Week 03 (Part A)
Topics:
Limiting the Rows Selected
Restricting with Character Strings and Dates
Comparison Conditions
Other Comparison Conditions,
Comparison Conditions
ORDER BY Clause
SELECT last_name, job_id, department_id, hire_date
FROM employees
ORDER BY hire_date DESC ;
Activity 01:
Display the employee last name, job ID, and start date of employees hired between
February 20, 2002, and May 1, 2004. Order the query in ascending order by start
date.
Activity 02:
Display the last name and department number of all employees in departments 20
and 50 in alphabetical order by name.
CSE 311L(Database Management System)
LAB-Week 03 (Part B)
Topics:
After completing this lesson, you should be able to restrict rows:
Using the LIKE Condition
Using the NULL Conditions
Logical Conditions
SELECT last_name
FROM employees
WHERE last_name LIKE “_o%”;
Activity 01:
Display the last name and hire date of every employee who was hired in 2004.
Activity 02:
Display the last name, salary, and commission for all employees who earn
commissions. Sort data in descending order of salary and commissions.
Activity 03:
Display the last name of all employees who have an a and an e in their last name.