PLSQL Chapter 7 Quiz

Welcome to your PLSQL Chapter 7 Quiz

1.
Can you have a BEGIN and END block within another BEGIN and END block?

2.
What is the difference between a package specification and a package body?

3.
What's wrong with this code?

CREATE PACKAGE emp_calc AS PROCEDURE calc_bonus(emp_id NUMBER);END emp_calc; /CREATE PACKAGE BODY emp_calc AS PROCEDURE calculate_bonus(emp_id NUMBER) AS BEGIN UPDATE emp SET bonus = salary * 0.1 WHERE id = emp_id; END;END emp_calc;/

4.
What happens if an error is found in a nested block, and it is handled by the EXCEPTION section and is passed to a DBMS_OUTPUT.PUT_LINE function?

This site uses Akismet to reduce spam. Learn how your comment data is processed.