Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

4-5 RUBAN command ption Page: 2 Name: . Based on the following relational schema Company (Company ID integer, name: string, address: string ) StaffStaffTD integer.

image text in transcribed4-5
RUBAN command ption Page: 2 Name: . Based on the following relational schema Company (Company ID integer, name: string, address: string ) StaffStaffTD integer. office string, email: string, phone: string Project (ProjectID integer, description: string, status: string Work(WorkID: integer, Company Perform(PerformID integer ID: integer, StafffD integer, since: date) , StafflD: integer, ProjectID integer, Start: date, End date) Write the SQL statements create all primary and foreign key integrity constraints. (25pts) Sond foreign key aen required to create the preceding relations, including appropriate versions of Suppliers Supplyld integer, sname: string, phone: string, address string, state: string) Parts(Partld integer, pname: string, color: string) Catalog(Supplyld integer, Partid: nteger, cost real) 5. Consider the following schema: (20pts) The key fields are underlined, and the domain of each field is listed after the field name. The Catalog relation lists the prices charged for parts by Suppliers. Write the following queries in relational algebra or SQL: (1) Find the names of suppliers (sname) who are located at "SC (2) Find the names of suppliers (sname) who supply parts less than $100 and the related PartID (3) Find the names and phone of suppliers (sname) who supply parts less than $100 and located at "SC (4) Find the SupplyID of suppliers who supply some red or yellow parts

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

identify sources of secondary data across organisations;

Answered: 1 week ago