Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Database Structure and Sample Data Here are brief descriptions of a few tables you'll be working with in the Californiana database: ca _ counties -
Database Structure and Sample Data
Here are brief descriptions of a few tables you'll be working with in the Californiana database:
cacounties This table contains basic information about the counties in California: name, location of the county seat, year in which the county was established, population, and area in square miles.
camountainranges A list of mountain ranges in California.
camountainpeaks A list of the fifty highest mountain peaks in California, including name, elevation and a pointer to the range to which the peak belongs.
cabooks A list of books that feature California in some significant way.
caauthors A list of authors who have written books about California.
cabookauthors A table that facilitates the manytomany relationship between books and authors since an author may have written more than one book, and books can have more than one author
Examples of rows you'll find in each of these tables are as follows:
cacounties
countyid name countyseat established population area
Placer Auburn
Sacramento Sacramento
Kern Bakersfield
camountainranges
rangeid name
Sierra Nevada
Cascades
Panamint Range
camountainpeaks
peakid name elevation rangeid
Double Mountain
Breckenridge Mountain
Crater Peak
cabooks
bookid title year
Roughing It
Celebrated Jumping Frog
Contested Eden: California Before the Gold Rush
Adventures of a Novelist
caauthors
authorid name
Twain, Mark
Atherton, Gertrude
Orsi, Richard
Gutirrez Ramn
cabookauthors
bookid authorid
Questions
Answer the following questions using the information provided above. Do not write SQL
pt What is the area of Sacramento county?
pt What city is the seat of Kern county?
pt In what mountain range is Breckenridge Mountain?
pt What are the titles of two books by Mark Twain in the database?
pt Who are the two authors of the book Contested Eden: California Before the Gold Rush?
pts Besides countyid what other field could serve as a primary key for the cacounties table? Explain your thinking.
pt Explain why population would not be a good field to select as the primary key for the cacounties table. Make sure that your explanation is supported by the definition of a primary key.
pts Identify two foreign key fields in the database. Provide the name of each field, and the name of the table in which each field resides.
pts What is the relationship between the camountainranges and camountainpeaks tables? Explain your thinking.
pts What would be a reasonable primary key for the cabookauthors table? Explain your thinking.
pts Imagine that you have a mountain peak named after you in the Panamint Range, and this is recorded in the Californiana database. Provide an example of what such a row might look like in the camountainpeaks table.
pt Suppose you've written a book about California, and this is recorded in the Californiana database. Provide an example of what such a row might look like in the caauthors table.
pt Suppose the book you've written is titled Weird Sacramento, and this is recorded in the Californiana database. Provide an example of what such a row might look like in the cabooks table.
pts What additional row would need to be added to the database to clearly indicate that you are the author of the book Weird Sacramento? Show what the row would look like, and identify the table in which it belongs.
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