PL/SQL Section 11 Quiz

 1. Which of the following exceptions can be raised ONLY when using the UTL_FILE package? (Choose two.)


(1) Point

2. The UTL_FILE package can be used to read and write binary files such as JPEGs as well as text files. True or False?

(1) Point

3. The DBMS_OUTPUT gives programmers an easy-to-use interface to see, for instance, the current value of a loop counter, or whether or not a program reaches a particular branch of an IF statement. (True or False?)

(1) Point

4. Which DBMS_OUTPUT package subprogram places text into the buffer at Line 1? (Choose one)

  IF v_bool1 AND NOT v_bool2 AND v_number < 25 THEN
    --Line 1
  ELSE
    ...
  END IF;
  DBMS_OUTPUT.NEW_LINE;

(1) Point

5. The UTL_FILE package contains several exceptions exclusively used in this package. Which are they? (Choose 3)

(1) Point

1. Using the FOPEN function, you can do which actions with the UTL_FILE package? (Choose 2)


(1) Point

2. Which general exceptions may be handled by the UTL_FILE package? (Choose 2)

(1) Point

3. The UTL_FILE package can be used to read and write binary files such as JPEGs as well as text files. True or False?

(1) Point

4. What will be displayed when the following code is executed?

BEGIN
    DBMS_OUTPUT.PUT('I do like');
    DBMS_OUTPUT.PUT_LINE('to be');
    DBMS_OUTPUT.PUT('beside the seaside');
END;


(1) Point

5. The DBMS_OUTPUT gives programmers an easy-to-use interface to see, for instance, the current value of a loop counter, or whether or not a program reaches a particular branch of an IF statement. (True or False?)

(1) Point
11. A package's state is initialized when the package is first loaded. True or False?

(1) Point

12. In the following example, which statement best fits in Line 1? (Choose 1)

DECLARE
 v_more_rows_exist BOOLEAN := TRUE;
BEGIN
 -- Line 1
 LOOP
   v_more_rows_exist := curs_pkg.fetch_n_rows(3);
  DBMS_OUTPUT.PUT_LINE('-------');
   EXIT WHEN NOT v_more_rows_exist;
 END LOOP;
 curs_pkg.close_curs;
END;


(1) Point

13. Users A and B call the same procedure in a package to initialize a global variable my_pkg.g_var. What will be the value of my_pkg.g_var for User A at Point A?

User A: my_pkg.g_var is 10
User B: my_pkg.g_var is 10
User A: my_pkg.g_var is 50
User B: my_pkg.g_var is 25
Point A


(1) Point

14. A cursor's state is defined only by whether it is open or closed and, if open, how many rows it holds. True or False?

(1) Point

15. Package CURSPACK declares a global cursor in the package specification. The package contains three public procedures: OPENPROC opens the cursor; FETCHPROC fetches 5 rows from the cursor's active set; CLOSEPROC closes the cursor.

What will happen when a user session executes the following commands in the order shown?
    curspack.openproc; -- line 1
    curspack.fetchproc; -- line 2
    curspack.fetchproc; -- line 3
    curspack.openproc; -- line 4
    curspack.fetchproc; -- line 5
    curspack.closeproc; -- line 6


(1) Point

1. The UTL_FILE package can be used to create binary files such as JPEGs as well as text files. True or False?


(1) Point

2. What will be displayed when the following code is executed?

BEGIN
    DBMS_OUTPUT.PUT('I do like');
    DBMS_OUTPUT.PUT_LINE('to be');
    DBMS_OUTPUT.PUT('beside the seaside');
END;


(1) Point

3. The UTL_FILE package contains several exceptions exclusively used in this package. Which are they? (Choose 3)

(1) Point

4. The DBMS_OUTPUT package is useful for which of the following activities? (Choose two)

(1) Point

5. The SEND procedure is for sending messages without attachments. True or False?

(1) Point

1. DBMS_OUTPUT.PUT_LINE can be invoked from inside a private packaged function. True or False?


(1) Point

2. Which of the following exceptions can be raised ONLY when using the UTL_FILE package? (Choose two.)

(1) Point

3. The UTL_FILE package contains several exceptions exclusively used in this package. Which are they? (Choose 3)

(1) Point

4. Which DBMS_OUTPUT package subprogram places text into the buffer at Line 1? (Choose one)

  IF v_bool1 AND NOT v_bool2 AND v_number < 25 THEN
    --Line 1
  ELSE
    ...
  END IF;
  DBMS_OUTPUT.NEW_LINE;

(1) Point

5. The UTL_FILE package can be used to read and write binary files such as JPEGs as well as text files. True or False?

(1) Point

Komentar

Postingan populer dari blog ini

PL/SQL Section 15 Quiz

PL/SQL Section 13 Quiz

PL/SQL Section 14 Quiz