Cyber Monday 2024! Hurry Up, Grab the Special Discount - Save 25% - Ends In 00:00:00 Coupon code: SAVE25
Welcome to Pass4Success

- Free Preparation Discussions

PostgreSQL Exam PGCES-02 Topic 11 Question 75 Discussion

Actual exam question for PostgreSQL's PGCES-02 exam
Question #: 75
Topic #: 11
[All PGCES-02 Questions]

The table "t1" is defined below. The column "id"

for table "t1" is of INTEGER type.

id | name ----

+-----------1 |

mammoth 2 |

tortoise 3 |

coelacanth

The following SQL statements were executed. Select the correct statement about the execution result. BEGIN; DECLARE c SCROLL CURSOR FOR SELECT name FROM t1 ORDER BY id;

MOVE FORWARD 2 FROM c; FETCH FORWARD ALL FROM c; COMMIT;

Show Suggested Answer Hide Answer
Suggested Answer: B

Contribute your Thoughts:

Julio
2 months ago
Oh man, cursors always trip me up. But I'm pretty sure the answer is C. Can't wait to be done with this exam and get back to my pet rock collection.
upvoted 0 times
Leigha
1 months ago
Definitely C, let's hope we're right.
upvoted 0 times
...
Annalee
1 months ago
I'm not sure, but C seems like the correct answer.
upvoted 0 times
...
Ernie
1 months ago
Yeah, I agree. C sounds right.
upvoted 0 times
...
Glenn
2 months ago
I think the answer is C.
upvoted 0 times
...
...
Virgina
2 months ago
I'm not sure, but I think the answer is C.
upvoted 0 times
...
Rasheeda
2 months ago
I agree with Pamella, the FETCH statement should return 1 row.
upvoted 0 times
...
Wilda
3 months ago
Hmm, I'm not so sure. The question mentions a SCROLL CURSOR, so I'm wondering if the cursor position can be reset somehow. Maybe the answer is D?
upvoted 0 times
...
Pamella
3 months ago
I think the correct answer is B.
upvoted 0 times
...
Kirk
3 months ago
I think the answer is C. The MOVE FORWARD 2 statement positions the cursor on the third row, and then the FETCH FORWARD ALL statement should return the remaining two rows.
upvoted 0 times
Kaycee
2 months ago
I believe it's A. The FETCH statement will return 0 rows because of an error in the execution.
upvoted 0 times
...
Latrice
2 months ago
I think it's B. The FETCH statement will return only 1 row after moving the cursor forward 2 positions.
upvoted 0 times
...
Cristen
2 months ago
I agree, the answer is C. The FETCH statement will return 2 rows after moving the cursor forward 2 positions.
upvoted 0 times
...
...

Save Cancel
az-700  pass4success  az-104  200-301  200-201  cissp  350-401  350-201  350-501  350-601  350-801  350-901  az-720  az-305  pl-300  

Warning: Cannot modify header information - headers already sent by (output started at /pass.php:70) in /pass.php on line 77