Exammagiccom 1z0 147 wwwexammagi ccom 27 which four

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: amp; C are Invalid Commands www.ExamMagic.com 1Z0-147 WWW.ExamMagi c.COM - 27: Which four triggering events can cause a trigger to fire? (Choose four) A. A specific error or any errors occurs. B. A database is shut down or started up. C. A specific user or any user logs on or off. D. A user executes a CREATE or an ALTER table statement. E. A user executes a SELECT statement with an ORDER BY clause. F. A user executes a JOIN statement that uses four or more tables. Answer: A,B,C,D Explanation: Correct Answers A, B & C: These are system events. Triggering events that cause system triggers to fire are Server Errors, Users Logging on or off the database, Database startup or shutdown, D: Database Triggers fire on DDL Statements including a CREATE, ALTER or DROP of a Table WWW.ExamMagic.COM - 28: Examine this procedure: CREATE OR REPLACE PROCEDURE ADD_PLAYER (V_ID IN NUMBER, V_LAST_NAME VARCHAR2) IS BEGIN INSERT INTO PLAYER (ID,LAST_NAME) VALUES (V_ID, V_LAST_NAME); COMMIT; END; This procedure must invoke the APD_BAT_STAT procedure and pass a parameter. Which statement, when added to the above procedure will successfully invoke the UPD_BAT_STAT procedure? A. EXECUTE UPD_BAT_STAT(V_ID); B. UPD_BAT_STAT(V_ID); C. RUN UPD_BAT_STAT(V_ID); D. START UPD_BAT_STAT(V_ID); Answer: B www.ExamMagic.com 1Z0-147 Explanation: Correct Answers Answer B When invoking a Procedure from within another procedure you omit the EXECUTE. You call the Procedure by specifying the Procedure Name and the argument list and a semi-colon Incorrect Answers: A. You omit the EXECUTE when calling a procedure from within a procedure. C. RUN is not valid for invoking a procedure D. Is invalid for invoking a procedure WWW.ExamMagic.COM - 29: Which statement about triggers is true? A. You use an application trigger to fire when a DELETE statement occurs. B. You use a database trigger to fire when an INSERT statement occurs. C. You use a system event trigger to fire when an UPDATE statement occurs. D. You use INSTEAD OF trigger to fire when a SELECT statement occurs. Answer: B Explanation: Answer: B Database trigger - Fires when a particular event occurs in the database. The events that fire a database trigger are Data events and System events. Data events consist of DML statements (INSERT, UPDATE & DELETE) and DDL statements, such as CREATE or DROP. System Events Comprised of actions that are performed either at the schema level or database level. Incorrect Answers: A. An Application trigger fires when a particular event occurs in the application. Application triggers aredeveloped using Oracle client-side tools, such as Oracle Forms Developer. C. The events that cause triggers created on system events to fire are: DDL statement on an object,Users logging on or off the database, Database shutdown or startup & Server errors. D. You can create an INSTEAD OF trigger on a view and use the trigger to perform DML on a view that is inherently non-updatable. WWW.ExamMagic.COM - 30: www.ExamMagic.com 1Z0-147 You want to create a PL/SQL block of code that calculates discounts on customer orders. -This code will be invoked from several places, but only within the program unit ORDERTOTAL. What is the most appropriate location to store the code that calculates the discounts? A. A stored procedure on the server. B. A block of code in a PL/SQL library. C. A standalone procedure on the client machine. D. A block of code in the body of the program unit ORDERTOTAL. E. A local subprogram defined within the program unit ORDERTOTAL. Answer: E WWW.ExamMagic.COM - 31: Which type of argument passes a value from a procedure to the calling environment? A. VARCHAR2 B. BOOLEAN C. OUT D. IN Answer: C Explanation: Parameters that are defined with an OUT mode the parameter will pass their value from the procedure back to the calling environment. Incorrect Answers: A. This is a DataType not a parameter B. This is a DataType not a parameter D. When a parameter is defined with an IN mode, the parameter will only accept input from the calling environment. WWW.ExamMagic.COM - 32: You create a DML trigger. For the timing information, which is valid with a DML trigger? A. DURING B. INSTEAD www.ExamMagic.com 1Z0-147 C. ON SHUTDOWN D. BEFORE E. ON STATEMENT EXECUTION Answer: D Explanation: BEFORE, AFTER and INSTEAD are valid Trigger Timing Events Incorrect Answers: A, C & E are not a valid Trigger Timing event B. INSTEAD OF, NOT INSTEAD is a valid DML Trigger Timing Event for a view WWW.ExamMagic.COM - 33: You are about to change the arguments of the CALC_TEAM_AVG function. Which dictionary view can you query to determine the names of the procedures and functions that invoke the CALC_TEAM_AVG function? A. USER_PROC_DEPENDS B. USER_DEPENDENCIES C. USER_REFERENCES D. USER_SOURCE Answer: B Explanation: The data dictionary view USER_DEPENDENCIES displays information about all direct dependencies within your schema. Incorrect Answers: A & C are not valid dictionary views D. USER_SOURCE: Provides the name and the source code fo...
View Full Document

Ask a homework question - tutors are online