Problem 4: SQL Queries Consider the following Relational schema and Relations instances. Patient (ID:char(9), p_name:varchar(25), City: varchar(50)) Prescription (Patient_ID:char(9),...

What is the solution for this question (using sql queries)Problem 4: SQL Queries<br>Consider the following Relational schema and Relations instances.<br>Patient (ID:char(9), p_name:varchar(25), City: varchar(50))<br>Prescription (Patient_ID:char(9), Medicine_code:char(5), Clinic:varchar(25))<br>Medicine (code:char(5), m_name:varchar, Ingredients:varchar, Price:float )<br>Patient<br>Prescription<br>ID<br>P_name<br>City<br>Patient_ID<br>Medicine_code<br>Clinic<br>112233445<br>Adam<br>Beirut<br>112233445<br>Nx306<br>Well Nutrition<br>998877665<br>Bob<br>Saida<br>112233445<br>Pa003<br>Healthy Clinic<br>556677889<br>Sara<br>Zahle<br>998877665<br>Ра003<br>Safe Clinic<br>443322445<br>Eve<br>Тyre<br>443322445<br>Ad500<br>Safe Clinic<br>443322445<br>Nx306<br>Well Nutrition<br>Medicine<br>code<br>M_name<br>Ingredients<br>Price<br>Ра003<br>Panadol<br>Potassium, Paracetamol, Starch<br>5.5<br>Nx306<br>Nexume<br>Magnesium, Polysorbate, Glyceryl<br>20.0<br>Ad500<br>Adol<br>Acetaminophen, Paracetamol<br>3.0<br>Ар800<br>Aspirin<br>Acetysalicylic Acid, Starch<br>8.55<br>Write SQL queries that will do the following:<br>1. List the name and the ID of all patients<br>2. List the price of Medicine called Nexume<br>3. Find the names of patients who have at least one prescription.<br>Page 6 of 7<br>

Extracted text: Problem 4: SQL Queries Consider the following Relational schema and Relations instances. Patient (ID:char(9), p_name:varchar(25), City: varchar(50)) Prescription (Patient_ID:char(9), Medicine_code:char(5), Clinic:varchar(25)) Medicine (code:char(5), m_name:varchar, Ingredients:varchar, Price:float ) Patient Prescription ID P_name City Patient_ID Medicine_code Clinic 112233445 Adam Beirut 112233445 Nx306 Well Nutrition 998877665 Bob Saida 112233445 Pa003 Healthy Clinic 556677889 Sara Zahle 998877665 Ра003 Safe Clinic 443322445 Eve Тyre 443322445 Ad500 Safe Clinic 443322445 Nx306 Well Nutrition Medicine code M_name Ingredients Price Ра003 Panadol Potassium, Paracetamol, Starch 5.5 Nx306 Nexume Magnesium, Polysorbate, Glyceryl 20.0 Ad500 Adol Acetaminophen, Paracetamol 3.0 Ар800 Aspirin Acetysalicylic Acid, Starch 8.55 Write SQL queries that will do the following: 1. List the name and the ID of all patients 2. List the price of Medicine called Nexume 3. Find the names of patients who have at least one prescription. Page 6 of 7

Jun 08, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here