Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Question I (80 points total) Consider the following relational database for storing data about employees and projects: employee (employee_ID, name, annual salary) project (project_name, budget)

image text in transcribed
image text in transcribed
Question I (80 points total) Consider the following relational database for storing data about employees and projects: employee (employee_ID, name, annual salary) project (project_name, budget) participation employee_ID, project_name) Question I (80 points total) Consider the following relational database for storing data about employees and projects: employee (employee_ID, name, annual salary) project (project_name, budget) participation employee_ID project_name) Assume that (i) the primary key for the employee table is {employee.ID), (i) the primary key for the project table is {project name}, (iii) an employee may participate in multiple projects, and (iv) multiple employees may participate in the same project. (a) (10 points) Identify an appropriate primary key for the participation table. Justify your choice of the primary key preferably in 2-3 sentences (e.g., why it is a candidate key). (b) (10 points) Create the participation table using SQL. Specify the primary and foreign keys as well as appropriate constraints if any. Assume that the employee and project tables are created as follows: create table employee employee_ID char (10) name varchar (30) annual salary numeric(9, 2). primary key (employee_ID)); create table project project_name varchar (30) budget numeric(11, 2), primary key (project_name)); () (10 points) Consider the following instance of the project table: project name budget Pi 1,000,000 P2 2,000,000 P3 3,000,000 Also, consider the following instance of the participation table: employee ID project name E1 P1 P3 P3 Is it possible to delete some records from the project table (not from the participation table) without violating any referential integrity? If so, explain which records can be deleted from the project table and briefly describe the reason. If not i.e., no record can be deleted from project), briefly explain the reason. P1 E2 E2 E3

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

Beginning Databases With PostgreSQL From Novice To Professional

Authors: Richard Stones, Neil Matthew

2nd Edition

1590594789, 978-1590594780

More Books

Students also viewed these Databases questions

Question

What is the Definition for Third Normal Form?

Answered: 1 week ago

Question

Provide two examples of a One-To-Many relationship.

Answered: 1 week ago