Lab 16 – PL (16 points) Place into one .sql file and upload to…

Question Answered step-by-step Lab 16 – PL (16 points) Place into one .sql file and upload to… Lab 16 – PL (16 points)Place into one .sql file and upload to Canvas. Problem 1 (6 pts)Create a function named GET_BALANCE_DUE (Finally!!  We don’t have to code it every time!)Input parameter is INVOICE_IDUse AP.INVOICES tableReturn the Balance Due (INVOICE_TOTAL – PAYMENT_TOTAL – CREDIT_TOTAL) Problem 2 (2 pts)Call the function GET_BALANCE_DUE, created above. Problem 3 (4 pts)Create a stored procedure named UPDATE_EMPLOYEEUpdate the EMPLOYEE (copy in your schema) table.  Pass in the EMPLOYEE_ID and SALARY.  Check to ensure the SALARY is positive.  Raise a custom application error if not.  Make the error easy for the user to understand. Problem 4 (4 pts)Call the stored procedure above. Call it once to create the error.Call it again to actually update the table.problem 2 and 3 please Engineering & Technology Computer Science CIS 275 Share QuestionEmailCopy link Comments (0)