Advanced Database Management System(3340701) Even 2022 Unit-2 PL/SQL and Triggers Course Outcome2 : Write PL/SQL block using concept of Cursor Management, Error Handling, Package and Triggers Sr No Questions Level
1 Describe PL/SQL.Explain its advantages of PL/SQL over SQL. R
2 Write a short Note on : Data types in PL/SQL U 3 Explain generic PL/SQL block with suitable example. U 4 Explain Anchored data type with example. U Write PL/SQL to read day from user, such as “SUNDAY” , and determine whether it is full day,half 5 A day or holiday.[Sunday is holiday,Saturday is half day, and all other days are full day.] Write PL/SQL code to determine the balance for a given account. If it is below 5000, Deduct a fine 6 A of Rs.100 from account once in a month. Write PL/SQL code which will give a rise in salary to the employee as per following rules: 1. If salary + commission < 3000 ,increase salary by 5% 7 A 2. If salary + commission >= 3000 ,increase salary by 10% 3. If salary + commission n above 7000 ,increase salary by 15% 8 Explain parameterized cursor with suitable example. U 9 Define exception and explain its types with suitable example R Insert a record in Account table.If branch name is other than ‘Gandhinagar’,’Ahmedabad’ ,raise and 10 A handle user defined exception 11 Describe Named and Numbered exceptions. R 12 Define Package .Give advantages of Package. U 13 Write steps to create Package with an example. A 14 List out types of Triggers and explain types of trigger with example. U 15 Differentiate :Triggers v/s Procedure U 16 Explain Procedure RAISE_APPLICTATION_ERROR U Write a PL/SQL program to update the salary of all analysts with 5%. Update the salary of all 17 employees with 20%. If total salary of all employees exceeds than Rs.1, 00,000 then undo the 20% A raise. 18 Differentiate :Functions v/s Procedure U 19 Write a function to find out the factorial of a given number. A 20 Write a procedure to print the fibonacci series of a given number. A