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

GN without SSA


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

New User


Joined: 03 Apr 2009
Posts: 47
Location: CHENNAI

PostPosted: Wed Mar 17, 2010 6:53 pm
Reply with quote

Hi All,
During one of the discussion regarding IMS Calls I came across a question wherein there is scenario in which GN Call is issued without any SSA's, this is processed in loop till GE is encountered. I believe that we will be accessing the all the segments in TOP to BOTTOM and then FRONT TO BACK and then LEFT TO RIGHT fashion for entire DB. But then as I can't access mainframe for sometime now(due to N/W issue) I was not able to try this scenario. Can any one throw some light on this. Also if there is a GN call issued with unqualified SSA on the child segment and no SSA being specified to the root segment, will the first occurence of the child segment in the DB retrieved? Please let me know if I am not clear on this.
Back to top
View user's profile Send private message
manikawnth

New User


Joined: 07 Feb 2007
Posts: 61
Location: Mumbai

PostPosted: Thu Mar 18, 2010 10:59 am
Reply with quote

Hi,

I still dont understand why you are looping till u encounter GE.
You read each and every segment of the DB as u mentioned, but as it is an unqualified CALL, you reach the End of Database hitting GB.

And for your second question it is YES.
With GN calls using an unqualified SSA of a child segment, you will be parsing all the occurrences of that segment type in the entire DB. But this result in poor-performance.
Are u just asking to learn or using it some where???


Thanks,
Manikanth
P.S: Do I make sense or Am I completely wrong?
Back to top
View user's profile Send private message
TAPAS PATEL

New User


Joined: 03 Apr 2009
Posts: 47
Location: CHENNAI

PostPosted: Thu Mar 18, 2010 4:53 pm
Reply with quote

Hi Manik,
Yes I am just asking to learn, I would have tried by myself but am not able to access Mainframes at the moment. For the first answer of yours, yes you are correct it should be GB and not GE. I am sorry it was out of haste I typed it.

I am still not clear on the second reply of yours when you say parsing, do you mean that for each segment type under a root I will get all the occurences of that segment concetnated? Please elobrate..
Back to top
View user's profile Send private message
Sandy Zimmer

Active Member


Joined: 13 Jun 2007
Posts: 826
Location: Wilmington, DE

PostPosted: Thu Mar 18, 2010 5:58 pm
Reply with quote

A GN call without ANY SSA will read every single segment in the database - all levels - all occurences. Your key feedback area will contain the concatenated key values of the root down. You will never get a GE. If you do not check for GB, you will start over at the beginning of the database and read and read and read.

If you use an unqualified SSA for a specific segment type, you will read every segment until you get a GB. If there are no segments for that type, you will get a GE.

You do not need the parent of your specified segment type. If you need to see the key values of the parents up the chain, you can take a look at the key feedback area in your PCB. For instance, you are looking for something in a segment 3 levels down. Once you determine that you have a segment with that value - look at the key feedback area for the parent key values.
Back to top
View user's profile Send private message
Sandy Zimmer

Active Member


Joined: 13 Jun 2007
Posts: 826
Location: Wilmington, DE

PostPosted: Thu Mar 18, 2010 6:09 pm
Reply with quote

Take a look at the structure in this post about multiple positioning:
ibmmainframes.com/viewtopic.php?t=47450

You are reading all segment7 - 2 levels down from the root. You are looking for a specific value in segment7. You are using a GN with 1 unqualified SSA - for segment7. You look at the field value in segment7 and it matches your agenda. Now you need to set a flag in segment1.

The first thing you do is look at your key feedback area to get the key value for your root. This is a great agenda for mulitple positioning. You use that key value to issue a qualified GU for the root - segment1 - using your second PCB. You are still positioned on your first PCB - not losing position - and you have been able to update segment1 up the chain.
Back to top
View user's profile Send private message
manikawnth

New User


Joined: 07 Feb 2007
Posts: 61
Location: Mumbai

PostPosted: Thu Mar 18, 2010 6:29 pm
Reply with quote

Hi Tapas,
For your doubt regarding my second reply, Sandy gave a clear explanation in her first post
Back to top
View user's profile Send private message
TAPAS PATEL

New User


Joined: 03 Apr 2009
Posts: 47
Location: CHENNAI

PostPosted: Fri Mar 19, 2010 1:02 pm
Reply with quote

Hi Manik,
Yes Indeed it was a great explaination. I have also tried this scenario and its working as explained. Thanks!!!

Hi Sandy,
Thanks for the explaination. I tried the scenario by giving GN call without an SSA and its working as given by you. For the scenario regarding the multiple positioning, In case I use second PCB and HOLD the root to update a field, will all the subsequent segments under that be locked as well? In this case will it affect the position of the first PCB?
Back to top
View user's profile Send private message
Lokesh Sahu

New User


Joined: 20 Feb 2012
Posts: 1
Location: India

PostPosted: Tue Mar 06, 2012 9:45 pm
Reply with quote

Hi,

I tried using GN a long back without using any SSAs and it took long time to run. I displayed key feedback of PCB and it gave the concatenated keys from root till end. It's a kind of dirty CALLS which shouldnot be used at practical scenarios.

Thanks & Regards
Lokesh
Back to top
View user's profile Send private message
Sandy Zimmer

Active Member


Joined: 13 Jun 2007
Posts: 826
Location: Wilmington, DE

PostPosted: Tue Mar 06, 2012 9:50 pm
Reply with quote

WOW!!! So, you found this old post.....don't forget if you are experimenting, always check for GB - end of database - or you will go thru the database over and over and over.
Back to top
View user's profile Send private message
Sandy Zimmer

Active Member


Joined: 13 Jun 2007
Posts: 826
Location: Wilmington, DE

PostPosted: Tue Mar 06, 2012 9:52 pm
Reply with quote

Oh, if someone still needs to know about the multiple positioning scenario, please just ask. The question is so old....
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

 


Search our Forums:

Back to Top