0% found this document useful (0 votes)
508 views8 pages

Final Questions MCQ

The document contains a PL/SQL exam with 50 marks and sections on PL/SQL fundamentals, cursors, exceptions, packages, triggers. It has multiple choice questions in each section testing knowledge of the relevant PL/SQL concepts.

Uploaded by

Karthik Raman
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
508 views8 pages

Final Questions MCQ

The document contains a PL/SQL exam with 50 marks and sections on PL/SQL fundamentals, cursors, exceptions, packages, triggers. It has multiple choice questions in each section testing knowledge of the relevant PL/SQL concepts.

Uploaded by

Karthik Raman
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
You are on page 1/ 8

Pl/sql exam

marks[50] passing [35] Time 40 min


Section 1

1. All variables must be defined in the ___________ section of the PL/SQL block . a. define section b. declarative section c. executable section d. exception section 2.The _________ variable attribute is used to define a row type variable a. scalar b. composite c. reference d. LOB 3. A PL/SQL block can be of _________ and _________ types. e. Singular and Multiple f. Nonprocedural and Procedural g. Anonymous and Named h. Declaration and Exception 4. PL/SQL provides ________, _________ and ________ data types . i. j. k. l. scalar, derived, composite composite, reference, user defined scalar, reference, LOB scalar, composite, LOB

5. ________ procedure produces output on the screen . m. n. o. p. DBMS_PRINT DBMS_OUTPUT DBMS_PUTOUT DBMS_OUT

6. EXIT statement brings the control q. out of PL/SQL Program. r. out of Section

s. out of CASE t. out of LOOP 7.A non PL/SQL variables are referenced : a. same as the PL/SQL variable b. by prefixing the colon(:) before variable name c. by suffixing the colon(:) after variable name d. by using period(.) notation

8. Within a FOR loop, the index variable cannot be changed by the user . a. TRUE b. FALSE 9. PL/SQL table is a user-defined data type . a. TRUE b. FALSE 10. SELECT statement when used in PL/SQL must return only one row . a. TRUE b. FALSE section 2 1. The cursor which is created by any SQL statement is: e. Implicit cursor f. Explicit cursor g. Parameterized cursor h. Cursor with SQL support 2. _________ clause within cursor exclusively locks the rows returned by the query a. FOR UPDATE clause b. WHERE CURRENT OF clause c. LOCK IN EXCLUSIVE MODE clause d. No such clause is used to lock the rows 3. __________ clause references the cursor to extract data from Particular row a. EXTRACT FROM Nth ROW b. WHERE CURRENT OF c. FETCH d. FETCH FROM Nth ROW 4. To binding entire columns of Oracle data, ________ clause is used by users

a. b. c. d.

BIND COLLECT BULK COLLECT GROUP COLUMN GROUP COLUMNS

5. ________ is used to refer the addresses of data items a. Implicit cursors b. Explicit cursors c. REF cursors d. Address pointers 6. ___________ cursor may be opened more than once in a block returning different working set each time a. An implicit cursor without any parameter b. A cursor with RETURN TYPE c. Parameterized cursor d. Active cursor 7. Working with parameterized cursors parameters need to be specified in a. Declaring cursor b. Opening cursor c. Fetching cursor d. Closing cursor 8. __________cursors need to be declare first before using them in the program a. Explicit cursors b. Parameterized cursors c. Implicit cursors d. Cursors with return type 9. The cursor FOR loop automatically opens a cursor and closes it a. TRUE b. FALSE 10. Explicit cursor attributes are defined with SQL% a. TRUE b. FALSE

section 3 1. _________ exceptions are internally defined by runtime system a. Runtime Exceptions

b. Predefined Exceptions c. Non-predefined Exceptions d. User defined Exceptions 2. Non-Predefined exceptions are raised in __________ a. Declarative section b. Executable section c. Exception Handling section d. Error Raising section 3. __________ handles all errors not already handled in the block a. Exception Handler b. Exception Handling Block c. WHEN OTHERS d. Error Code 4. Non-Predefined exceptions are handled by ___________ a. Error Functions b. Exception Handlers c. PRAGMA EXCEPTION_INIT d. RAISE_APPLICATION_ERROR 5. ___________ is used to create your own error messages a. SQLCODE b. SQLERRM c. User Defined Exceptions d. RAISE_APPLICATION_ERROR 6. __________ is defined in EXCEPTION section of PL/SQL block a. Error b. Exception c. Exception handler d. Error code 7. All User defined Exceptions raised in ___________section of a PL/SQL block a. Declarative b. Executable c. Exception Handling d. Error Coding 8. One block can have only one exception handler a. TRUE b. FALSE 9. Non predefined exceptions must not be declared in the declarative section a. TRUE

b. FALSE 10. An exception having same name can not be redeclared in the same block a. TRUE b. FALSE

section 4 1. The ________ option is used with the CREATE command to Mobile an existing procedure a. PROCEDURE b. IS|AS c. REPLACE d. NEW 2. To drop a package user must have ______ system privileges a. DROP PROCEDURE b. DROP ANY PROCEDURE c. DROP PROCEDURE <procedure-name> d. DELETE PROCEDURE 3.__________ is a feature that allows you to define different subprograms with the same name a. Operator overloading b. Method overloading c. Subprogram overloading d. Package overloading 4. Creating a package is a ________ step process a. One b. Two c. Five d. Seven 5. Default mode of an argument is _________ a. IN b. OUT c. IN OUT d. DEFAULT

6. The _________ parameters are passed by reference a. Actual b. Formal c. IN d. OUT 7. The __________ parameters are passed by value a. Actual b. Formal c. IN d. OUT 8. __________ is used to write dynamic SQL in stored procedures and to parse DDL statements a. Dynamic SQL b. DBMS_SQL c. Parser d. Lexical Analyzer 9. __________ is used to write DDL statements in an Anonymous block a. DBMS_OUTPUT b. DBMS_DDL c. DBMS_SQL d. EXECUTE IMMEDIATE 10. __________ is used to access data on the Internet a. UTL_TCP b. UTL_HTTP

c. UTL_IP d. UTL_SMTP
section 5

1. ___________ command is used to create a trigger a. CREATE OR REPLACE TRIGGER b. CREATE TRIGGER c. REPLACE TRIGGER d. CREATE TRIGGER <trigger-name> FOR <select> statement 2. ___________ clause is used to specify a trigger to be a row level trigger a. FOR ROW LEVEL b. FOR EVERY ROW c. FOR EACH ROW d. FOR ROW WISE 3. ___________ clause is used to restrict a row level trigger a. WHERE b. WHEN c. HAVING d. GROUP BY 4. The three conditional predicates are __________, ___________ and _____________ a. INSERT, UPDATE, DELETE b. INSERTION, UPDATION, DELETION c. INSERTING, UPDATING, DELETING d. INSERT_CONDITION, UPDATE_CONDITION, DELETE_CONDITION 5. Old value and new value of a column are referenced by ________ and _________ qualifiers respectively a. OLD , NEW b. old, new c. :old , :new d. old: , new: 6. Triggers are invoked in a program ___________ a. implicitly when an event occurs b. explicitly by the users when an event occurs c. implicitly by the server when ever any DML statement issued d. whenever timeout occurs 7. __________ triggers are used for virtual tables

a. Statement level triggers b. Row level triggers c. INSTEAD OF triggers d. VIEW triggers 8. ________ triggers are used for Oracle Front-end Applications a. Database triggers b. Application triggers c. Oracle Forms triggers d. Front-end triggers 9. If you create statement level trigger for a table, you cannot create row level trigger for the same table a. TRUE b. FALSE 10. Multiple triggers of the same type can be created for a table a. TRUE b. FALSE

You might also like