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

Use of occurs in a segment layout


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

New User


Joined: 17 Jan 2008
Posts: 1
Location: Pune

PostPosted: Thu Jan 17, 2008 6:18 pm
Reply with quote

Hi, I want to understand, how the following segment layout will be stored in the IMS DB.

XAK1WWWN CHAR (1)
XAK1JMAKT CHAR (4)
XAK1UAKT(1:11)
XAK1UBEN CHAR(30)
XAK1USTDNO FIXED(7,0)
XAK1ANTUT FIXED(7,0)
XAK1RUN CHAR(1)
XAK1WWWF CHAR (1)

As the XAK1UAKT fields is occurring a number of time. If I have data only in four occurences then physically when it's stored, will IMS occupy the space for complete 11 occurences or just only 4 occurences?
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 Jan 17, 2008 8:14 pm
Reply with quote

If it is NOT at the end of a variable length segment, it will be stored in all occurences. You will need to remember to initialize those not used.

Sometimes we use variable length segments with an occurs at the very end of the segment. For instance, you would use this for monthly buckets. You would then adjust your segment length based on how many occurences you are using.
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 Updating a 1 byte thats in occurs mul... DFSORT/ICETOOL 6
No new posts IMS SEGMENT READ ISSUE IMS DB/DC 1
This topic is locked: you cannot edit posts or make replies. I HAVE 2 INPUT FILES WITH SAME LAYOUT... COBOL Programming 6
No new posts Inserting records into the empty segm... IMS DB/DC 1
No new posts REORG to reduce segment size new DBD IMS DB/DC 2
Search our Forums:

Back to Top