Assignment Dbms
Assignment Dbms
SESSION: 2024-25
Submitted in partial fulfilment of
the requirement for the award of
the degree of
Bachelor of Technology In COMPUTER science
ENGINEERING(AI/ML)
Table :- EmpSalary
Table :- Project
ProjectId Duration
p-1 23
p-2 15
p-3 45
p-4 2
p-5 30
OUTPUT
104 or E-102.
SQL code
OUTPUT
4. What is the department name for DeptID E-102?
SQL code
SQL code
output
6. select the name of the employee whose name's 3rd charactor is 'h'.
SQL code
SQL code
SELECT COUNT(*) FROM Salaries
WHERE IsPermanent = 'Yes' AND Salary > 5000;
OUTPUT
SQL code
SELECT SUM(Salary) FROM Salaries
WHERE IsPermanent = 'Yes';
OUTPUT
10. How many project started and finished in the same year
SQL code
SELECT COUNT(*) FROM Projects
WHERE YEAR(StartDate) = YEAR(EndDate);
OUTPUT