Bug #872: Cursor scrolling

From: pgsql-bugs(at)postgresql(dot)org
To: pgsql-bugs(at)postgresql(dot)org
Subject: Bug #872: Cursor scrolling
Date: 2003-01-13 06:39:22
Message-ID: 20030113063922.28AD4475EB9@postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Artur Zajac (azajac(at)student(dot)uci(dot)agh(dot)edu(dot)pl) reports a bug with a severity of 3
The lower the number the more severe it is.

Short Description
Cursor scrolling

Long Description
There is some example in attachment. Sometimes after second fetch I had 0 rows (in other query). It seems that there is a bug in cursor scrolling or cursors doesn't let to move backward in some cases.

Sample Code
create table abc (a varchar(5),r int);
insert into abc VALUES ('FV','1');
insert into abc VALUES ('WZ','2');
insert into abc VALUES ('RW','3');
insert into abc VALUES ('PF','4');
select * from abc; ---- returns 4 rows
BEGIN;
DECLARE aaa CURSOR FOR SELECT DISTINCT ON (r) r,a FROM abc WHERE a!='';
FETCH ALL FROM aaa; ---- returns 4 rows
MOVE BACKWARD 26 IN aaa; --- returns MOVE 3 (why???)
FETCH ALL FROM aaa; ---- returns 3 rows

No file was uploaded with this report

Browse pgsql-bugs by date

  From Date Subject
Next Message pgsql-bugs 2003-01-13 18:55:55 Bug #873: 7.3.1 install fails for RH7.3... cannot find ascii_and_mic.so
Previous Message Andrzej Kosmala 2003-01-12 21:46:54 "ERROR: Query-specified return tuple and actual function return tuple do not match" after dropping column