lease write a stored procedure which will display the student’s transcript by the input (semester, year). The program needs to meet the following requirements and test cases. .If the input year is “*”, the report should have all students for all years. If the input semester is “*”, the report should have all the terms in that year. If the input semester or year is empty or null, a corresponding error message should be printed. If there is no student for the input semester/year, the output message should say “year xxxx, semester zzzz has no students in the system”. If there are students found for the input semester/year, print the report with the format based on the test cases. The report should be sorted by the student’s last_name, first_name from A to Z, year from low to high, and semester from spring to fall.
Please write a stored procedure which will display the student’s transcript by the input (semester, year). The program needs to meet the following requirements and test cases.
.If the input year is “*”, the report should have all students for all years.
If the input semester is “*”, the report should have all the terms in that year.
If the input semester or year is empty or null, a corresponding error message should be printed.
If there is no student for the input semester/year, the output message should say “year xxxx, semester zzzz has no students in the system”.
If there are students found for the input semester/year, print the report with the format based on the test cases.
The report should be sorted by the student’s last_name, first_name from A to Z, year from low to high, and semester from spring to fall.
![MariaDB [dreamhome]> Select * from Students;
| sid
| first_name
1001 | Austin
1002 Mary
1003
Claudia
Lee
1004 | Andrew
Lin
1005 | Helen
Wu
1007 Sarah
| Lee
6 rows in set (0.010 sec)
MariaDB [dreamhome]> Select * from Courses;
| cid
| name
| credits |
| last_name | birthday | major
| Huang
Smith
1990-01-01 CS
1976-02-08 | IT
1987-03-21 | Math
1947-08-25 | Biology
1997-01-25 | CS
1995-09-15 | IT
Java1
Java2
| cid
CPS1231
CPS2231
CPS2232 Data Structure
CPS3500 Web Programming
CPS3740 | Database Introductio
CPS5920 Database Systems
| CPS5921 | Data Mining
7 rows in set (0.014 sec)
MariaDB [dreamhome]> Select * from
| sid
1001
CPS2231 2013 Fall
1003 CPS2231 2015 | Spring
1004 CPS2231 2014 | Spring
1001
CPS2232 2016 Fall
1004
CPS2232 2014
1005
CPS2231 2016
1007
CPS2231
2015
1003
CPS5920 2016
1007
CPS3740
2014
2016 | Spring
2017 | Spring
1003 CPS5921
1001 CPS3500
1003 | CPS2231 2014 Fall
1004 CPS2232 2014 Fall
| 1004 | CPS2231 | 2013 | Fall
14 rows in set (0.001 sec)
| year | semester | grade |
| A-
Spring
Spring
Spring
Fall
Fall
Students_Courses;
<< < ± <_UARTLOU
| A
A-
| C+
B+
| B
| C
| A
4
4
4
3
3 |
3
3 |
| C+
| F
| C
C
| zipcode
|
07123
08348
91384
07101
07083
04101](/v2/_next/image?url=https%3A%2F%2Fcontent.bartleby.com%2Fqna-images%2Fquestion%2F2ec814c7-90f3-4435-9bb8-fcbab3f733ac%2F4ddeef20-0103-4b2b-afb4-b738e362e4af%2Fc35s3ja_processed.png&w=3840&q=75)

Step by step
Solved in 3 steps









