PL/SQL Section 4 Quiz

 1. Look at the following block:

DECLARE
  v_date DATE := SYSDATE;
BEGIN
  WHILE v_date < LAST_DAY(v_date) LOOP
    v_date := v_date + 1;
  END LOOP;
  DBMS_OUTPUT.PUT_LINE(v_date);
END;

If today's date is 17th April 2007, what will be displayed when this block executes?


(1) Point

2. Which statement best describes when a FOR loop should be used?

(1) Point

3. When using a counter to control a FOR loop, which of the following is true ?

(1) Point

4. The EXIT statement can be located anywhere inside a basic loop. True or False?

(1) Point

5. A PL/SQL block contains the following code:
v_counter := 1;
LOOP
    EXIT WHEN v_counter=5;
END LOOP;
v_counter := v_counter + 1;

What is the value of V_COUNTER after the loop is finished?


(1) Point

Komentar

Postingan populer dari blog ini

PL/SQL Section 15 Quiz

PL/SQL Section 13 Quiz

PL/SQL Section 14 Quiz