Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

(1) Implement and comprehensively test a statement trigger that verifies the following consistency constraint. An applicant cannot apply more than three positions in one day.

(1) Implement and comprehensively test a statement trigger that verifies the following consistency constraint. An applicant cannot apply more than three positions in one day. (2) Implement and comprehensively test a row trigger that verifies the following consistency constraint. The value of position number must be continuous. "Contiguous" in a relationship to the position number means, that the first position must have a number 1, the second position must have a number 2, and each next position must have a number greater by one than a number of the previous position. Hint: To avoid "mutating table" error, insert a line PRAGMA AUTONOMOUS_TRANSACTION At the beginning of DECLARE block. When ready save your CREATE TRIGGER statement and all SQL statements that comprehensively test a trigger in a script solution1.sql. Comprehensive testing means that the trigger must reject SQL statements that violate the consistency constraint and accept SQL statements that do not violate the consistency constraint. It is a part of your task to find what SQL statements should be tested. Whenever SQL statement violates the consistency constraint a trigger must return ORA- error message. Use a procedure RAISE_APPLICATION_ERROR to return ORA- error message. If SQL statement does not violate the consistency constraint then a trigger must return no messages.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

OCA Oracle Database SQL Exam Guide Exam 1Z0-071

Authors: Steve O'Hearn

1st Edition

1259585492, 978-1259585494

More Books

Students also viewed these Databases questions

Question

Detailed note on the contributions of F.W.Taylor

Answered: 1 week ago

Question

4.3 Describe the job analysis process and methods.

Answered: 1 week ago