Saved Bookmarks
| 1. |
Write the outputs of the SQL queries (i) to (iii) based on the relations Teacher and Posting given below:Table : TeacherT_IDNameAgeDepartmentDate_of_joinSalaryGender1Jugal34Computer Sc10/01/201712000M2Shaemila31History24/03/200820000F3Sandeep32Mathematics12/12/201630000M4Sangeeta35History01/07/201540000F5Rakesh42Mathematics05/09/200725000M6Shyam50History27/06/200830000M7Shiv Om44Computer Sc25/02/201721000M8Shalakha33Mathematics31/07/201820000FTable : PostingP_IDDepartmentPlace1HistotyAgra2MathematicsRaipur3Computer ScienceDelhii. SELECT Department, count(*) FROM Teacher GROUP BY Department; ii. SELECT Max(Date_of_Join),Min(Date_of_Join) FROM Teacher; iii. SELECT Teacher.name,Teacher.Department, Posting.Place FROM Teachr, Posting WHERE Teacher.Department = Posting.Department AND Posting.Place=”Delhi”; |
|||||||||||||||||
|
Answer» OUTPUT: i.
ii. Max - 31/07/2018 or 2018-07-31 Min- 05/09/2007 or 2007-09-05 iii.
|
||||||||||||||||||