MVSFORUMS.com Forum Index MVSFORUMS.com
A Community of and for MVS Professionals
 
 FAQFAQ   SearchSearch   Quick Manuals   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

What are Scrollable cursors?

 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Database
View previous topic :: View next topic  
Author Message
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12376
Topics: 75
Location: San Jose

PostPosted: Sun Dec 01, 2002 10:59 pm    Post subject: What are Scrollable cursors? Reply with quote

Scrollable and non-scrollable cursors
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Kev
Beginner


Joined: 02 Jan 2003
Posts: 2
Topics: 0

PostPosted: Thu Jan 02, 2003 10:53 am    Post subject: Reply with quote

Scrollable cursors allow you to scroll through a set of results forward, backward, to the start, to the end, etc. See DB2 V7 manuals for detailed info.
Back to top
View user's profile Send private message
raj051076
Beginner


Joined: 05 Dec 2002
Posts: 64
Topics: 21

PostPosted: Sat Jan 04, 2003 3:03 pm    Post subject: Reply with quote

Scrollable cursor is a cool feature of DB2 version 7. We can scroll forward or backward once the cursor is open. There are two types of scrollable cursor sensitive and insensitive.

Also you need to use temprary tables to use scrollable cursors. Following key words are supported in scrollable cursors.

next
prior
first
last
current
before
after
absolute n
relative n

DECLARE <CURSORNAME> SENSITIVE STATIC SCROLL CURSOR
FOR SELECT EMPLOYEENAME, ADDRESS
FROM EMP
ORDER BY EMPLOYEEID;

OPEN <CURSORNAME>;

FETCH LAST <CURSORNAME> INTO :NAME, :ADDRESS;
_________________
Rajib
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Database All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


MVSFORUMS
Powered by phpBB © 2001, 2005 phpBB Group