subject

Consider the following relational schema, where the primary keys are Bold,
Students(sid, sname, address, dept_id)
Courses(cid, cname, dept_id)
Departments(dept_id, dname, college)
Grades(sid, cid, year, semester, grade)
Write the following queries in SQL. Only use the tables that are absolutely needed for the corresponding query.
1. Find the sids and snames of students who took "Database" course (i. e., cname = ‘Database’) in Fall 2019.
2. Find the average grade of all the students who took "CS327" (i. e., cid=‘CS327’) in Fall 2019. You can assume grade is a numerical attribute.
3. Find the number of distinct courses offered by each department in Fall 2019.
4. Find the sids of students who have taken at least 10 different courses offered by "Computer Science" department (i. e., dname = ‘Computer Science’).

ansver
Answers: 3

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 23:30
For her science class, elaine is creating a presentation on weather in the united states. she wants to make the presentation beautiful and interesting by drawing simple cloud or wave shapes. which is the best way for elaine to draw these shapes?
Answers: 1
question
Computers and Technology, 23.06.2019 22:20
If i uninstall nba 2k 19 from my ps4 will my career be gone forever?
Answers: 2
question
Computers and Technology, 24.06.2019 02:00
Write an expression that will cause the following code to print "equal" if the value of sensorreading is "close enough" to targetvalue. otherwise, print "not equal". ex: if targetvalue is 0.3333 and sensorreading is (1.0/3.0), output is:
Answers: 1
question
Computers and Technology, 24.06.2019 02:20
The first time a user launches the powerpoint program, which view is shown allowing the user to access recent presentations or create new presentations based on templates?
Answers: 1
You know the right answer?
Consider the following relational schema, where the primary keys are Bold,
Students(sid, snam...
Questions
question
Mathematics, 05.05.2020 03:20
question
Mathematics, 05.05.2020 03:20
Questions on the website: 13722360