Question: Question 4: (12 Marks) Given the following schema: Doctor(DID, Dname, Specialty) Patient(Pid, Pname, Age, Weight) Diagnose(PID, DID, date, description) Prescription(PID, MId, date, comment) Medicine (Mid,

 Question 4: (12 Marks) Given the following schema: Doctor(DID, Dname, Specialty)

Question 4: (12 Marks) Given the following schema: Doctor(DID, Dname, Specialty) Patient(Pid, Pname, Age, Weight) Diagnose(PID, DID, date, description) Prescription(PID, MId, date, comment) Medicine (Mid, MName, type) Write down the following queries in SQL: 1. List the doctors who are specialist in Diabetes. 2. List the patients of Dr. Mshari 3. Retrieve the patients who were diagnosed by Dr. Mshari and Dr. Ghamdi 4. Retrieve all the medicine that were taken by Fadh Zahrani before 10/4/2016 and prescribed before 1/4/2016 5. Retrieve the number of patients who were diagnosed by Dr. Mshari before the 10/5/2016 6. List for each specialty and for each doctor the number of patient who were diagnosed

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock 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 Databases Questions!