VSAM RRDS vs Relative file



Support for OS/VS COBOL, VS COBOL II, COBOL for OS/390 & VM and Enterprise COBOL for z/OS

VSAM RRDS vs Relative file

Postby mbattu » Thu Mar 02, 2017 10:18 am

Hi, I am trying to understand differences between

1) Physical Sequential vs ESDS
2) Index Sequential vs KSDS
3) Relative vs RRDS

I understand that ESDS is similar to Physical Sequential except that it can be accessed Directly although in CICS only using Relative Byte address

KSDS is similar to Index Sequential except that KSDS has separate index and the organization is in CI & CA. Index Sequential can be defined using RECORG=KS and specifying the KEYLEN in JCL

RRDS can be defined using IDCAMS and mentioning NUMBERED in it. Can anyone help me understand difference between Relative and RRDS and how Relative File can be defined.

Thank you for your response.
mbattu
 
Posts: 9
Joined: Wed Nov 27, 2013 8:26 am
Has thanked: 4 times
Been thanked: 0 time

Re: VSAM RRDS vs Relative file

Postby steve-myers » Thu Mar 02, 2017 11:03 am

  • ESDS / non-VSAM sequential - You can obtain ESDS records by RBA in all environments, not just CICS. Non-VSAM sequential can be accessed by record number by using BDAM in some situations.
  • KSDS / indexed sequential - All VSAM data sets are organized in control intervals and control areas, though they are significant only in KSDS.
  • Perhaps you can tell us your understanding of a "relative file."

These users thanked the author steve-myers for the post:
mbattu (Thu Mar 02, 2017 1:39 pm)
steve-myers
Global moderator
 
Posts: 2105
Joined: Thu Jun 03, 2010 6:21 pm
Has thanked: 4 times
Been thanked: 243 times

Re: VSAM RRDS vs Relative file

Postby enrico-sorichetti » Thu Mar 02, 2017 12:23 pm

cheers
enrico
When I tell somebody to RTFM or STFW I usually have the page open in another tab/window of my browser,
so that I am sure that the information requested can be reached with a very small effort

These users thanked the author enrico-sorichetti for the post:
mbattu (Thu Mar 02, 2017 1:26 pm)
enrico-sorichetti
Global moderator
 
Posts: 3006
Joined: Fri Apr 18, 2008 11:25 pm
Has thanked: 0 time
Been thanked: 165 times

Re: VSAM RRDS vs Relative file

Postby mbattu » Thu Mar 02, 2017 1:39 pm

Thanks Enrico, the document is very useful.

Thanks Steve for the information. Going through the document Enrico has provided that, I understand that there will be fixed number of slots which can retrieved by its Relative Record Number. Only DATA part is defined in the cluster and no Index part. Now I only wonder whether we can define a non VSAM relative file. If there is no such thing as non VSAM relative file, please let me know. Thank you again for your time in helping me understand.
mbattu
 
Posts: 9
Joined: Wed Nov 27, 2013 8:26 am
Has thanked: 4 times
Been thanked: 0 time

Re: VSAM RRDS vs Relative file

Postby willy jensen » Thu Mar 02, 2017 3:30 pm

I guess that the closest you can get is a direct access dataset.
willy jensen
 
Posts: 467
Joined: Thu Mar 10, 2016 5:03 pm
Has thanked: 0 time
Been thanked: 70 times

Re: VSAM RRDS vs Relative file

Postby steve-myers » Fri Mar 03, 2017 2:46 am

mbattu wrote:Thanks Enrico, the document is very useful.

Thanks Steve for the information. Going through the document Enrico has provided that, I understand that there will be fixed number of slots which can retrieved by its Relative Record Number. Only DATA part is defined in the cluster and no Index part. Now I only wonder whether we can define a non VSAM relative file. If there is no such thing as non VSAM relative file, please let me know. Thank you again for your time in helping me understand.


Evidently you did not read the first bullet in my first post. Mr. Jensen alludes to this in his post. The primary qualifier is the data set pretty much has to be defined as RECFM=FBS. If the data set is defined as RECFM=FBS, your program has to translate the relative record number to a relative block and record in the block and use BDAM to read the correct relative block and then move to the correct record in the block.
steve-myers
Global moderator
 
Posts: 2105
Joined: Thu Jun 03, 2010 6:21 pm
Has thanked: 4 times
Been thanked: 243 times


Return to IBM Cobol

 


  • Related topics
    Replies
    Views
    Last post