Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Step 1: Similar to homework 2, add additional students to the registered_students table for class CS-HU310 where the student's first_name contains a 'p'. This time

image text in transcribedimage text in transcribedimage text in transcribedimage text in transcribed

Step 1: Similar to homework 2, add additional students to the registered_students table for class CS-HU310 where the student's first_name contains a 'p'. This time you are required to use a JOIN (i.e. don't hardcode the class_id). Deliverable 1: send your code & screenshot Step 2: Write a SELECT statement that returns ALL classes and the number of students taking the class. Use an aggregate function. Use a group by clause Use an alias to name this column number_of_students Include the following columns: classes.class_id, classes.code, number_of_students and the classes.maximum_students Output Example: number_of_students maximum_students dass_id code 1 CS-HU310 3 COMM113 4 ENG 101 MA030 11 4 6 0 10 5 4 5 Note: Your counts may be different Deliverable 2: send your code & screenshot NO Limit to 1000 rows Query 1 x 17 Ta 1 . select * from classes 2 TIT Result Grid Result Grid 1 Filter Rows: dass_id name 1 Computer Science 310 SQL 3 Communications 4 Engineers 5 Math NULL Edit: D Export/Im description code maxir NULL CS-HU310 10 Teaches communication COMM113 5 Teaches engineering ENG 101 4 Teaches maths MA030 5 NULL NULL NULL NULL Form Editor Field Types Query 1 x Limit to 1000 rows 1. select * from registered_students 2 MIT Result Grid Filter Rows: Edit: G B - Export/Im id class_id student_id signup_timestamp 1 1 1 2021-02-01 20:03:09 Result Grid Query 1 x 17 Ta o 90 select * from students 3 Limit to 1000 rows 2 Edit: 42 Export/Im Result Grid Filter Rows: student_id first_name_last_name birthdate Ross Johnson 2015-12-17 Result Grid Step 1: Similar to homework 2, add additional students to the registered_students table for class CS-HU310 where the student's first_name contains a 'p'. This time you are required to use a JOIN (i.e. don't hardcode the class_id). Deliverable 1: send your code & screenshot Step 2: Write a SELECT statement that returns ALL classes and the number of students taking the class. Use an aggregate function. Use a group by clause Use an alias to name this column number_of_students Include the following columns: classes.class_id, classes.code, number_of_students and the classes.maximum_students Output Example: number_of_students maximum_students dass_id code 1 CS-HU310 3 COMM113 4 ENG 101 MA030 11 4 6 0 10 5 4 5 Note: Your counts may be different Deliverable 2: send your code & screenshot NO Limit to 1000 rows Query 1 x 17 Ta 1 . select * from classes 2 TIT Result Grid Result Grid 1 Filter Rows: dass_id name 1 Computer Science 310 SQL 3 Communications 4 Engineers 5 Math NULL Edit: D Export/Im description code maxir NULL CS-HU310 10 Teaches communication COMM113 5 Teaches engineering ENG 101 4 Teaches maths MA030 5 NULL NULL NULL NULL Form Editor Field Types Query 1 x Limit to 1000 rows 1. select * from registered_students 2 MIT Result Grid Filter Rows: Edit: G B - Export/Im id class_id student_id signup_timestamp 1 1 1 2021-02-01 20:03:09 Result Grid Query 1 x 17 Ta o 90 select * from students 3 Limit to 1000 rows 2 Edit: 42 Export/Im Result Grid Filter Rows: student_id first_name_last_name birthdate Ross Johnson 2015-12-17 Result Grid

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Expert Oracle9i Database Administration

Authors: Sam R. Alapati

1st Edition

1590590228, 978-1590590225

More Books

Students also viewed these Databases questions

Question

How do modern Dashboards differ from earlier implementations?

Answered: 1 week ago