Question: learn _ zybooks.com / zybook / Database _ Essentials _ for _ Business _ with _ Lab _ _ _ 1 1 5 0 6
learnzybooks.comzybookDatabaseEssentialsforBusinesswithLabchaptersection
My library BIS : Database Essentials for Business with Lab home Join queries
zyBooks catalog
HelpFAQ
PARTICIPATION
ACTIVITY
: Join coding exercise.
The SQL below creates Genre and Song tables, inserts some genres and songs, and performs an inner join.
Run the SQL Verify the result table does not include songs with NULL genre or genres that are not associated with songs.
Make the following changes:
In the CREATE TABLE statement for Song, rename GenreCode to Code. Modify the SELECT statement to work with the new name. Run the SQL and verify the result table is unchanged.
Modify the SELECT statement to perform a left join. Run the SQL and verify the result table includes songs with NULL genre
Modify the SELECT statement to perform a right join. Run the SQL and verify the result table includes genres that are not associated with any songs:
Combine the left and right joins into one statement that performs a full join. Run the SQL and verify the result table includes all songs and genres.
HintsIn steps and use keywords LEFT and RIGHT. In step use keyword UNION, since MySQL does not support FULL JOIN.
CREATE TABLE SOng
COde CHAR
Name VARCHAR
Description VARCHAR
PRIMARY KEYCode
Search
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
