Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Student ( sid , name, did, avgGrade ) Take ( sid , cid, grade ) Course ( cid , title, credits, did, avgGrade ) Department
Student sid name, did, avgGrade
Take sid cid, grade
Course cid title, credits, did, avgGrade
Department did name, avgGrade
Teacher tid name, did, avgGrade
Teach tid cid
Write the following questions in SQL using the database schema above.
List the ID and grades of the student named 'Ali KURT' name
List the records ie all columns of the course table of the courses taken by the student named Aye KURT' name but not taken by the student named 'Ali KURT'.
List the students' SIDs and the number of courses they took, their GPA, their highest and lowest grades.
List the did's of the departments and the number of students in descending order according to the number of students Do not write in relational algebra
List the sid's of the professors who teach more than courses, the number of courses they teach and the number of students taking their courses.
List the records list all fields in the student table of the fields use take table from the students in the department named 'Computer Engineering' departmentname and the courses in the department named 'Electrical Engineering' departmentname
Find the average of the number of students in each course the number of students taking each course will be determined from the take table, and then the average of these numbers will be found and list the enrollments of the courses with more students than this average. first the cids of the courses with more students than the average will be found, then based on these cids the course records in the course table will be found
List the records of students who took two different courses without using GROUP BYSince there are different course subjects, the take table needs to be used twice! First, the sids of these students will be found with a subquery then the records in the student table, that is all columns, will be accessed through these sids.
List the professors who do not teach any lessons this means there is no record of this teacher in the teaching table
List the records of the instructors all columns in the teacher tableThat is all teachers with tid in the teach tableYukardaki veritabanemasn kullanarak aadaki sorular SQL ile yaznz
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started