IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

IMS DB Last segment call under a root segment


IBM Mainframe Forums -> IMS DB/DC
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
wreets79

New User


Joined: 18 Dec 2006
Posts: 1
Location: Kolkata, India

PostPosted: Mon Dec 18, 2006 5:21 pm
Reply with quote

Hi,

I need to call the last occurance of the child segment under a parent root segment. Example Root segment is 'A' under which there are 5 child segments 'B'.

Through one IMS call (not with GN call till i get the last call) the last segment is to be retrieved.
Back to top
View user's profile Send private message
guptae

Moderator


Joined: 14 Oct 2005
Posts: 1208
Location: Bangalore,India

PostPosted: Mon Dec 18, 2006 5:46 pm
Reply with quote

Hi There,

U can give two ssa

Code:
02 SSA-ASEG-QUALIFIED.                               
   03 SSA-SEGMENT-NAME              PIC X(8) VALUE 'A'.     
   03 SSA-COMMAND-CODE            PIC X(4) VALUE SPACES.       
   03 SSA-BEGIN-QS                      PIC X     VALUE '('.           
   03 SSA-KEY-NAME                      PIC X(8) VALUE 'KEYNAME'.       
   03 SSA-R-O                               PIC XX   VALUE 'EQ'.         
   03 SSA-KEY-VALE                      PIC X(11)VALUE 'specify the value of 
                                                   that rool key value'                                     
   03 SSA-END-QS                        PIC X    VALUE ')'.


Code:
02 SSA-BSEG.                                               
    03 FILLER                        PIC X(8)  VALUE 'B'.
    03 SSA-COMMAND-CODE              PIC X(4)  VALUE '*L--'.     


Code:
CALL 'CBLTDLI' USING  GU-FUNC                 
                                   PCB-MASK               
                                   B-SEGMENT   
                                   SSA-ASEG-QUALIFIED 
                                   SSA-BSEG.


Hope it will helpful
Back to top
View user's profile Send private message
Bitneuker

CICS Moderator


Joined: 07 Nov 2005
Posts: 1104
Location: The Netherlands at Hole 19

PostPosted: Tue Dec 19, 2006 3:23 pm
Reply with quote

Correct Ekta. In addition my 2 cents. It's depending on where your gained position in the database. If you already did the GU on the root a simple GNP on the child with command code *L may do. Another option; if you didn't read the root yet and you want it too you may use a pathcall using command code *D and an appropriate IO-area.

So.....it always depends on the actions you did before your required next move. Please provide us with that information next time.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> IMS DB/DC

 


Similar Topics
Topic Forum Replies
No new posts Error while running web tool kit REXX... CLIST & REXX 5
No new posts Call program, directly from panel CLIST & REXX 9
No new posts Batch call online program, EXCI task ... CICS 3
No new posts CSQBGET - Call giving completion code... COBOL Programming 3
No new posts CICS DPL call CICS 6
Search our Forums:

Back to Top