Last active
September 7, 2022 16:54
-
-
Save theabhayprajapati/b3ad333528d7a2d3421a7c1a48ce5b88 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT e.Empno, e.LastName, d.DeptName from Employee e, Department d WHERE e.DeptID = d.DeptId ORDER BY d.DeptName,e.LastName DESC; | |
SELECT e.lastName, d.DeptID, d.DeptName from Employee e, Department d WHERE e.DeptID = d.DeptId; | |
SELECT DISTINCT desgn from Employee where DeptId = 1; | |
SELECT e.LastName, d.DeptName from Employee e, Department d WHERE e.LastName LIKE '%a%' AND e.DeptId = d.DeptID; | |
SELECT e.LastName, d.DeptName, d.City from Employee e, Department d WHERE e.DeptId = d.DeptId AND e.desgn = 'Manager' ORDER BY e.Empno; | |
SELECT CONCAT(e.FirstName, " ", e.LastName) "Employee", CONCAT(m.LastName, " ", m.FirstName) FROM Employee m INNER JOIN Employee e ON m.Desgn="Manager" AND e.DeptID = m.DeptId; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment