Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

a. “The chair of the department has requested a current list of all student majo

ID: 3806026 • Letter: A

Question

a. “The chair of the department has requested a current list of all student majors in ascending order by major and then name that are currently in the database. The example output is show below”. (Required to use only one SELECT with an INNER JOIN. HINT: ORDER BY)

b. “The chair of the department is planning a conference call with most of the faculty and many of the graduate assistants. She has asked you to query the database and provide all classrooms on campus that will hold more than 20 people and have a phone. The example output requested is shown below”. (Required to use only one SELECT with an INNER JOIN. HINT: WHERE clause with a logical AND)

Explanation / Answer

a. select majorSubject,Name from Student s inner join Subject s1 on s.majorSubject=s1.majorSubject order by Name;

b. select ClassName from Class c inner join Phone P on c.phonenum=P.phonenum where seatno>=20 and phonenum<>Null;