- Create a simple view showing the names of employees whose designation is ”Instructor”
SELECT EmployeeName, Designation, FROM Employees
WHERE Designation = 'Instructor'
- Create a view to list down employees name and designation of Computer sciences Department
SELECT EmployeeName, Designation, DepartmentID, FROM Employees
WHERE DepartmentID = '1'
- Update view to change designation from instructor to lecturer of employee “Ali hassan”
SELECT EmployeeName, Designation, FROM Employees
WHERE Designation = 'instructor' OR Designation= 'lecturer')
- Create a view to show number of courses student “VU001” is studying.
SELECT CourseID, StudentID, FROM Employees
WHERE StudentID IN (' VU001')
No comments:
Post a Comment