Question: Question 1 (18 marks, 3 marks each). For each of the following statements, represent it using CREATE TABLE statement. Note that there are both

Question 1 (18 marks, 3 marks each). For each of the following statements, represent it using CREATE TABLE

Question 1 (18 marks, 3 marks each). For each of the following statements, represent it using CREATE TABLE statement. Note that there are both entity sets and relationship sets to be considered. 1. Patients attend doctors. You want to store the attending information and the date of attending. Patients identified by pid. Doctors is identified by did. 2. Continue 1, each patient attends doctors at most once. 3. Continue 2, each patient attends doctors at least once. 4. Continue 1, only existing doctors can be attended by a patient. 5. Continue 1, every doctor must be attended by a patient. 6. Continue 1, each of (Name, Address) and (Name, Age) uniquely identifies a patient.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

Question 1 CREATE TABLE Statements Based on Constraints 1 Base Schema Attending Info with Date sql CREATE TABLE Patient pid INT PRIMARY KEY CREATE TAB... View full answer

blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!