DB Lab 11 - Muneeb Ashraf
DB Lab 11 - Muneeb Ashraf
“DataBase SQL”
Submitted by:
Muneeb Ashraf
Subject:
Database - SQL
Sem. & Dept:
BSSE-4A (Morning)
Date:
4-12-2024
Submitted to:
Madam. Syeda Maryam Tahir
1 | Page
Lab # 11:
CREATE DATABASE LabTask11;
USE LabTask11;
2 | Page
JOIN Department d ON e.DepartmentID = d.DepartmentID
LEFT JOIN Project p ON e.EmployeID = p.EmployeID;
Question # 01:
Retrieve the list of employees along with
their department names.
Question # 02
Retrieve a list of projects along with the names of employees
assigned to them.
3 | Page
Question # 03
Retrieve the list of employees, their
department names, and the projects they are assigned to.
4 | Page
Question # 04:
Retrieve a list of all employees and their
department names. Include employees who are not assigned
to any department.
Question # 05:
Retrieve a list of all departments and
the employees in those departments. Include departments
with no employees.
5 | Page
Question # 06:
Retrieve a list of all employees and their
department names. Include employees without a department
and
departments without employees.
6 | Page