Question: You are working for the ( A B C ) Clinic, a small medical clinic that is open 7 days per week. The

You are working for the \( A B C \) Clinic, a small medical clinic that is open 7 days per week. The clinic would like to generate a reminder telephone call to clinic patients the day before their scheduled appointments. A vendor has a software application that will do this, given the appropriate data from the clinic database. You have been asked to investigate how to obtain the necessary data from the clinic's relational database. You are to begin with a small test database.
The following figure shows the entities in the clinic database, namely, doctors, patients, and clinic appointments. Doctor
ClinicAppointment
Please answer these questions:
10. Write three SQL queries to display the full contents of each of the three tables.
11. Now write a query to return the information used by the reminder program. The query must take a date and return the doctors first and last name, the patients first and last name and both phone numbers, and the appointment time, so it can produce a voice message of the form:
has an appointment with doctor at on .
Write the query to obtain data for all patients for February 28,2018.(Hint: Your query will need two Join operations. Also, there are attributes in both the Doctor and Patient tables with the same names. You will need
to qualify them with their table names, for example, Doctor.FirstName.)
Show the results of your query.
12. Someone has suggested that if the clinic is going to remind the patients, they should also remind the doctors. The query must take the doctors ID and a date and return the doctors first and last name and the appointment time so it can produce a voice message of the form: doctor , you have an appointment at on .
Write the query to obtain data for all appointments for DoctorID DO1 on 2/27/2018, ordered by appointment time. Show the results of your query.
You are working for the \ ( A B C \ ) Clinic, a

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 Programming Questions!