Saved Bookmarks
| 1. |
Mr. Som, a HR Manager in a multinational company “Star-X world” has created the following table to store the records of employees: Table: EmpEidENameDepartmentDOBDOJStar1IvanSales1994-08-282020-02-14Star2MelindaIT1997-10-152021-11-19Star3RajAccounts1998-10-022019-04-02Star4MichaelSales2000-02-172020-05-01Star5SajalIT2001-12-052018-06-13Star6JohnAccounts1995-01-032019-07-15Star7JuliaSales1985-11-132020-08-19He has written following queries: i) select max(year(DOB)) from emp; ii) select ENAME from emp where month(DOJ)=11; Predict the output. OR Based on the table given above, help Mr. Som writing queries for the following task: i) To display the name of eldest employee and his/her date of birth. ii) To display the name of those employees whose joining month is May. |
||||||||||||||||||||||||||||||||||||||||
|
Answer» Mr. Som, a HR Manager in a multinational company “Star-X world” has created the following table to store the records of employees: Table: Emp
Output: i) 2001 ii) Melinda OR Queries: i) select ENAME,min(year(DOB)) from emp; ii) select ENAME from emp where month(DOJ)=5; |
|||||||||||||||||||||||||||||||||||||||||