lint all files
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
3. List the names of patients who are at least fifty years old. Your query should always generate a list in which the names are sorted in alphabetical order. The ordering must not depend upon the order in which you entered data into your database.
|
||||
1. List the names of patients who are at least fifty years old. Your query should always generate a list in which the names are sorted in alphabetical order. The ordering must not depend upon the order in which you entered data into your database.
|
||||
|
||||
```SQL
|
||||
SELECT patient_name
|
||||
@@ -9,7 +9,7 @@ ORDER BY patient_name;
|
||||
|
||||

|
||||
|
||||
4. List the name of each type of organ, together with the total number of donations of that type of organ.
|
||||
1. List the name of each type of organ, together with the total number of donations of that type of organ.
|
||||
|
||||
```SQL
|
||||
SELECT organ_type, COUNT( organ_type )
|
||||
@@ -20,7 +20,7 @@ GROUP BY organ_type;
|
||||
|
||||

|
||||
|
||||
5. List the identifiers of hospitals where a transplant has been performed, together with the number of transplant operations at the hospital.
|
||||
1. List the identifiers of hospitals where a transplant has been performed, together with the number of transplant operations at the hospital.
|
||||
|
||||
```SQL
|
||||
SELECT hospital_id, COUNT( hospital_id )
|
||||
@@ -31,7 +31,7 @@ GROUP BY hospital_id;
|
||||
|
||||

|
||||
|
||||
6. Output the age of the oldest person who has donated in a hospital in Manchester.
|
||||
1. Output the age of the oldest person who has donated in a hospital in Manchester.
|
||||
|
||||
```SQL
|
||||
SELECT age
|
||||
@@ -49,4 +49,4 @@ WHERE donor_id IN (
|
||||
)
|
||||
)
|
||||
);
|
||||
```
|
||||
```
|
||||
|
||||
Reference in New Issue
Block a user