Question: Building a Multi-Table DB with Relationships (Include the tables creation query, I will dislike if you copy the answer from bartleby because it's wrong)
Question: Building a Multi-Table DB with Relationships (Include the tables creation query, I will dislike if you copy the answer from bartleby because it's wrong)
Database System Concepts
7th Edition
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Chapter1: Introduction
Section: Chapter Questions
Problem 1PE
Related questions
Question
Question: Building a Multi-Table DB with Relationships
(Include the tables creation query, I will dislike if you copy the answer from bartleby because it's wrong)
(Include the tables creation query, I will dislike if you copy the answer from bartleby because it's wrong)
(Include the tables creation query, I will dislike if you copy the answer from bartleby because it's wrong)
In this assignment, you will build a copy of the "Music"
Then you must construct and run some queries on your data and then take screen shots of those queries and submit the screen shots as your assignment.
![Sample Screen Shots
phpMyAdmin
de
(Recent tables)...
New
imported
information_schema
6-
misc
mijs
mmo
mmorps
moodle
Music
New
Album
Artist
Genre
Track
mysql
People
performance_schema
pr4e
Frest
rest demo
sakai10
sakai11
tsugi
由izap
phpMyAdmin
公园日 3
(Recent tables)...
New
imported
information_schema.
misc
mijs
mmorps
moodle
Music
New
Album
Artist
Genre
Son
Track
mysql
People
performance_schema
pr4e
rest
rest demo
sakai10
sakai11
tsugi
zap
#
Table: Track
+ Server: localhost:8889» Database: Music »
Browse Structure SQL O Search Insert Export Import
✔Showing rows 0-3 (4 total, Query took 0.0003 sec)
SELECT FROM "Track
Number of rows: 25 #
Sort by key: None
+ Options
SET FOR TOMTO nutink
+ Options
name
name
Led Zepplin Rock
T→
O EditCopy X Delete
EditCopy X Delete
Copy X Delete
Copy X Delete
Edit
Edit
to Check All
0
O
Number of rows: 25
Artist.name = 'Led Zepplin'
+ Options
Number of rows: 25 +
+
title
About to Rock
Who Made Who
Black Dog
Stairway
+
With selected:
Number of rows: 25 +
track_id
Profiling [Inline ] [ Edit ] [ Explain SQL ] [ Create PHP Code ] [ Refresh ]
-Query results operations
Print view Print view (with full texts) Export Display chart Create view
title
1 Black Dog
2 Stairway
3 About to Rock
4 Who Made Who
Change X Delete
Showing rows 0 - 0 (1 total, Query took 0.0004 sec)
Server: localhost:8889 » Database: Music »
Table: Track
Browse Structure SQL Search Insert Export Import ✓ More
title
name
AC/DC
AC/DC
Who Made Who
Who Made Who
Led Zepplin IV
Led Zepplin IV
len rating count album_id
297
482
313
207
Export
Show query box
Current selection does not contain a unique column. Grid edit, checkbox, Edit, Copy and Delete features
are not available.
✓ Showing rows 0-3 (4 total, Query took 0.0004 sec)
select Track.title, Artist.name, Album.title, Genre.name from Track join Genre join Album join Artist on
Track.genre_id = Genre.genre_id and Track.album_id= Album.album_id and Album.artist_id = Artist.artist_id
Profiling [Inline ] [ Edit ] [ Explain SQL ] [ Create PHP Code ] [ Refresh ]
name
Metal
Metal
Rock
Rock
5
5
5
5
Number of rows:
25 +
-Query results operations
Print view Print view (with full texts) Export Display chartCreate view
Server: localhost:8889 »
Database: Music » Table: Track
Browse Structure SQL Search Insert Export Import ✓ More
0
0
0
0
More
Show query box
Current selection does not contain a unique column. Grid edit, checkbox, Edit, Copy and Delete
features are not available.
Number of rows: 25 +
-Query results operations
Print view Print view (with full texts) Export Display chart
Canna nama PDOK SAL TOTH Alhum TOTE CARna ТАТМ
2
2
1
1
genre_id
Create view
1
1
2
2
Antint 111 m.album_id
HERE
Profiling [Inline ] [ Edit ] [ Explain SQL ] [ Create PHP Code ] [ Refresh ]
Ā](/v2/_next/image?url=https%3A%2F%2Fcontent.bartleby.com%2Fqna-images%2Fquestion%2F5915e225-7260-4e29-b3a4-94bc502c1b17%2Fc57035c4-d63e-467a-88c7-27f2af728e85%2Fxdynext_processed.jpeg&w=3840&q=75)
Transcribed Image Text:Sample Screen Shots
phpMyAdmin
de
(Recent tables)...
New
imported
information_schema
6-
misc
mijs
mmo
mmorps
moodle
Music
New
Album
Artist
Genre
Track
mysql
People
performance_schema
pr4e
Frest
rest demo
sakai10
sakai11
tsugi
由izap
phpMyAdmin
公园日 3
(Recent tables)...
New
imported
information_schema.
misc
mijs
mmorps
moodle
Music
New
Album
Artist
Genre
Son
Track
mysql
People
performance_schema
pr4e
rest
rest demo
sakai10
sakai11
tsugi
zap
#
Table: Track
+ Server: localhost:8889» Database: Music »
Browse Structure SQL O Search Insert Export Import
✔Showing rows 0-3 (4 total, Query took 0.0003 sec)
SELECT FROM "Track
Number of rows: 25 #
Sort by key: None
+ Options
SET FOR TOMTO nutink
+ Options
name
name
Led Zepplin Rock
T→
O EditCopy X Delete
EditCopy X Delete
Copy X Delete
Copy X Delete
Edit
Edit
to Check All
0
O
Number of rows: 25
Artist.name = 'Led Zepplin'
+ Options
Number of rows: 25 +
+
title
About to Rock
Who Made Who
Black Dog
Stairway
+
With selected:
Number of rows: 25 +
track_id
Profiling [Inline ] [ Edit ] [ Explain SQL ] [ Create PHP Code ] [ Refresh ]
-Query results operations
Print view Print view (with full texts) Export Display chart Create view
title
1 Black Dog
2 Stairway
3 About to Rock
4 Who Made Who
Change X Delete
Showing rows 0 - 0 (1 total, Query took 0.0004 sec)
Server: localhost:8889 » Database: Music »
Table: Track
Browse Structure SQL Search Insert Export Import ✓ More
title
name
AC/DC
AC/DC
Who Made Who
Who Made Who
Led Zepplin IV
Led Zepplin IV
len rating count album_id
297
482
313
207
Export
Show query box
Current selection does not contain a unique column. Grid edit, checkbox, Edit, Copy and Delete features
are not available.
✓ Showing rows 0-3 (4 total, Query took 0.0004 sec)
select Track.title, Artist.name, Album.title, Genre.name from Track join Genre join Album join Artist on
Track.genre_id = Genre.genre_id and Track.album_id= Album.album_id and Album.artist_id = Artist.artist_id
Profiling [Inline ] [ Edit ] [ Explain SQL ] [ Create PHP Code ] [ Refresh ]
name
Metal
Metal
Rock
Rock
5
5
5
5
Number of rows:
25 +
-Query results operations
Print view Print view (with full texts) Export Display chartCreate view
Server: localhost:8889 »
Database: Music » Table: Track
Browse Structure SQL Search Insert Export Import ✓ More
0
0
0
0
More
Show query box
Current selection does not contain a unique column. Grid edit, checkbox, Edit, Copy and Delete
features are not available.
Number of rows: 25 +
-Query results operations
Print view Print view (with full texts) Export Display chart
Canna nama PDOK SAL TOTH Alhum TOTE CARna ТАТМ
2
2
1
1
genre_id
Create view
1
1
2
2
Antint 111 m.album_id
HERE
Profiling [Inline ] [ Edit ] [ Explain SQL ] [ Create PHP Code ] [ Refresh ]
Ā
![Question: Building a Multi-Table DB with Relationships
In this assignment, you will build a copy of the "Music" database covered in
lecture. You will populate your database with tracks, artists, albums and
genres that are different from the ones used in class. You must include three
artists, five albums, and 20 tracks in your data. Choose a genre for each
track. Your tables need to normalized as described in class.
Then you must construct and run some queries on your data and then take
screen shots of those queries and submit the screen shots as your
assignment.
Artist
artist_id
name
Album
album_id
title
artist_id
Genre
genre_id
name
Track
track_id
title
rating
len
count
album_id
genre_id
What to Hand in
For this assignment you will hand in:
1. Screen shot (JPG or PNG) of data in the Track table
2. Screen shot (JPG or PNG) of all the data joined up sorted in
ascending order by the album title
3. Screen shot (JPG or PNG) of all of the genres for a particular artist.
Hint - use JOIN, DISTINCT and WHERE](/v2/_next/image?url=https%3A%2F%2Fcontent.bartleby.com%2Fqna-images%2Fquestion%2F5915e225-7260-4e29-b3a4-94bc502c1b17%2Fc57035c4-d63e-467a-88c7-27f2af728e85%2Fgx6uvj8_processed.jpeg&w=3840&q=75)
Transcribed Image Text:Question: Building a Multi-Table DB with Relationships
In this assignment, you will build a copy of the "Music" database covered in
lecture. You will populate your database with tracks, artists, albums and
genres that are different from the ones used in class. You must include three
artists, five albums, and 20 tracks in your data. Choose a genre for each
track. Your tables need to normalized as described in class.
Then you must construct and run some queries on your data and then take
screen shots of those queries and submit the screen shots as your
assignment.
Artist
artist_id
name
Album
album_id
title
artist_id
Genre
genre_id
name
Track
track_id
title
rating
len
count
album_id
genre_id
What to Hand in
For this assignment you will hand in:
1. Screen shot (JPG or PNG) of data in the Track table
2. Screen shot (JPG or PNG) of all the data joined up sorted in
ascending order by the album title
3. Screen shot (JPG or PNG) of all of the genres for a particular artist.
Hint - use JOIN, DISTINCT and WHERE
Expert Solution
![](/static/compass_v2/shared-icons/check-mark.png)
This question has been solved!
Explore an expertly crafted, step-by-step solution for a thorough understanding of key concepts.
This is a popular solution!
Trending now
This is a popular solution!
Step by step
Solved in 2 steps with 2 images
![Blurred answer](/static/compass_v2/solution-images/blurred-answer.jpg)
Knowledge Booster
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.Recommended textbooks for you
![Database System Concepts](https://www.bartleby.com/isbn_cover_images/9780078022159/9780078022159_smallCoverImage.jpg)
Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education
![Starting Out with Python (4th Edition)](https://www.bartleby.com/isbn_cover_images/9780134444321/9780134444321_smallCoverImage.gif)
Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON
![Digital Fundamentals (11th Edition)](https://www.bartleby.com/isbn_cover_images/9780132737968/9780132737968_smallCoverImage.gif)
Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON
![Database System Concepts](https://www.bartleby.com/isbn_cover_images/9780078022159/9780078022159_smallCoverImage.jpg)
Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education
![Starting Out with Python (4th Edition)](https://www.bartleby.com/isbn_cover_images/9780134444321/9780134444321_smallCoverImage.gif)
Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON
![Digital Fundamentals (11th Edition)](https://www.bartleby.com/isbn_cover_images/9780132737968/9780132737968_smallCoverImage.gif)
Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON
![C How to Program (8th Edition)](https://www.bartleby.com/isbn_cover_images/9780133976892/9780133976892_smallCoverImage.gif)
C How to Program (8th Edition)
Computer Science
ISBN:
9780133976892
Author:
Paul J. Deitel, Harvey Deitel
Publisher:
PEARSON
![Database Systems: Design, Implementation, & Manag…](https://www.bartleby.com/isbn_cover_images/9781337627900/9781337627900_smallCoverImage.gif)
Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781337627900
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning
![Programmable Logic Controllers](https://www.bartleby.com/isbn_cover_images/9780073373843/9780073373843_smallCoverImage.gif)
Programmable Logic Controllers
Computer Science
ISBN:
9780073373843
Author:
Frank D. Petruzella
Publisher:
McGraw-Hill Education