Question: For the queries below provide screenshots along with the code in your MS word response document a . List the students who have not enrolled
For the queries below provide screenshots along with the code in your MS word response document
a List the students who have not enrolled in any course. Include their names and student IDs.
b Find out the average grade for each course. Display the course name and its average grade.
c Write a query to find the students who have not enrolled in any course offered by Professor Dr Smith. Display the student name and ID
d Write a query to find the students who have the highest grade in each department. Display the student name, department name, and the grade. If there are multiple students with the highest grade in a department, include all of them.
e Write a query to list the courses that have at least one student with a grade of A and at least one student with a grade of B Display the course name and the department name.
f Find the students who have the highest grade in each course. Display the student name, course name, and the grade.
g Write a query to display the courses with enrollment counts greater than the average enrollment count. Display the course name and the number of students enrolled in each course.
Following are the data corresponding to the tables in the Database.
STUDENT
StudentID FirstName LastName DateOfBirth Address Email PhoneNumber
John Doe Cityville john.doe@email.com
Jane Smith Townsville jane.smith@email.com
Mark Johnson Villagetown mark.johnson@email.com
Emily Davis Hamletville emily.davis@email.com
David Wilson Riverside david.wilson@email.com
Sarah Turner Mountainville sarah.turner@email.com
Alex Brown Valleytown alex.brown@email.com
COURSE:
CourseID CourseName Credits DepartmentID
Introduction to DB
Advanced SQL
Data Modeling
Database Security
Big Data Analytics
NoSQL Databases
Data Warehousing
PROFESSOR:
ProfessorID FirstName LastName DepartmentID Email PhoneNumber
Prof Johnson prof.johnson@email.com
Dr Smith drsmith@email.com
Prof Anderson prof.anderson@email.com
Dr Davis drdavis@email.com
Prof Miller prof.miller@email.com
Dr Turner drturner@email.com
Prof White prof.white@email.com
DEPARTMENT:
DepartmentID DepartmentName Location
Computer Science Building A
Information Tech Building B
Management Building D
Finance Building C
ENROLLMENT:
EnrollmentID StudentID CourseID EnrollmentDate Grade
A
B
A
C
B
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
