Question: Programming with SQL (10 points) Write Java JDBC methods to maintain the tot.cred attribute of the student relation in the University schema under the following

 Programming with SQL (10 points) Write Java JDBC methods to maintain

Programming with SQL (10 points) Write Java JDBC methods to maintain the tot.cred attribute of the student relation in the University schema under the following operations: 1. INSERT into the takes table (1 point) DELETE from the takes table (1 point) UPDATE of the course table (1 point) 2. Write a Java JDBC method that computes the histogram of the grades for a given course in a given semester of a year (course title, semester, and year are input parameters). The method returns a map having as key the grade, e.g., A, A-, A+, B, B-, B+, etc., and as value the number of students that got that grade in the input course, year, semester. (3 points) 3. Consider an employee database with two relations employee (employee.name, street, city) and works (employee_name, company_name, salary). Find the companies whose employees earn a higher salary on average than the average salary of a given company. Provide two solutions: A SQL stored function/procedure that takes the company as an input argument and prints the result companies. (2 points) A Java JDBC program with a method solving the query. (2 points) Programming with SQL (10 points) Write Java JDBC methods to maintain the tot.cred attribute of the student relation in the University schema under the following operations: 1. INSERT into the takes table (1 point) DELETE from the takes table (1 point) UPDATE of the course table (1 point) 2. Write a Java JDBC method that computes the histogram of the grades for a given course in a given semester of a year (course title, semester, and year are input parameters). The method returns a map having as key the grade, e.g., A, A-, A+, B, B-, B+, etc., and as value the number of students that got that grade in the input course, year, semester. (3 points) 3. Consider an employee database with two relations employee (employee.name, street, city) and works (employee_name, company_name, salary). Find the companies whose employees earn a higher salary on average than the average salary of a given company. Provide two solutions: A SQL stored function/procedure that takes the company as an input argument and prints the result companies. (2 points) A Java JDBC program with a method solving the query. (2 points)

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!