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 

IMS, DL/1 and DB2 positioning

 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Application Programming
View previous topic :: View next topic  
Author Message
misi01
Advanced


Joined: 02 Dec 2002
Posts: 618
Topics: 172
Location: Stockholm, Sweden

PostPosted: Sun Aug 21, 2022 5:55 am    Post subject: IMS, DL/1 and DB2 positioning Reply with quote

Background
We are running IMS and converting DL/1 programs to DB2.
One of the programs is a 3270 one using the usual MFS panel.
The program ONLY reads the DL/1 database.
The logic in the program is approximately this:
Code:
S100:
   perform read-mid
   if PF3-equivalent, leave
   perform process-input
   perform write-mod
   go to S100


(the program was written in 1984 !!!!)

The program allows the user to scroll left/right by 4 DL/1 segments at a time.
One of the aspects of it that has puzzled me is the following.
Assume this scenario: -
Users sees first 4 segments (1-4). Presses PF11 to see 5-8.
The first thing the program does is to do a GU on the root, then read "past" the first 4
after which reads segments 5-8 and presents them

I can see that, having done a GU on the root, it has to read "past" previous segments to
get to its starting point, but my first question would be. is the GU necessary, or is
it a case that IMS might have/has swapped the program out, and as a result, when it's swapped
back in, the child position has been lost?

Now, to the equivalent DB2 cursor code. I saw some interesting links on declaring a cursor as scrollable (never used it myself).
- does it work in IMS and do I need to declare the cursor as FOR HOLD?
- is IMS potentially swapping the program in and out goint to be a problem such that the cursor is lost?
_________________
Michael
Back to top
View user's profile Send private message Send e-mail
kolusu
Site Admin
Site Admin


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

PostPosted: Sun Aug 21, 2022 7:00 am    Post subject: Reply with quote

misi01,

Probably the MFS panel is defined with an array of 4 entries at a time. So you fetch the data for first 4 segments and present it. The next segments retrieval is a brand new call as the program does NOT know where the pointer is and hence the GU call.

As for DB2 you don't have to worry about it as you can now define a bigger array and then show the contents. Cursor with HOLD is done to avoid closing the cursor when a commit or syncpoint is done (typically updating the contents of the cursor)
_________________
Kolusu - DFSORT Development Team (IBM)
DFSORT is on the Web at:
www.ibm.com/storage/dfsort

www.linkedin.com/in/kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Application Programming 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