-
Hi I was wondering if anyone can help me.
Given this PL/SQL block
DECLARE
v_counter INTEGER :=1;
v_upper INTEGER :=10;
BEGIN
WHILE v_counter = v_upper LOOP
INSERT INTO test(results)
VALUES(v_counter);
IF v_counter = 5 THEN
v_upper := 7;
END IF;
v_counter := v_counter + 2;
END LOOP;
END;
How many rows will be inserted into the test table? Choose the best answer
A. 10
B. 7
C. 5
D. 3
E. 4
The answer given in my book is E. 4 But I don't know how they got this answer.
How do I read the Loop.????
Can you plug in the numbers to show me how you deal with this problem. Thanks.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|