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

How to Change the Relative Record number for user wish?


IBM Mainframe Forums -> JCL & VSAM
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
Rajesh S
Warnings : 1

New User


Joined: 11 Jul 2007
Posts: 54
Location: Chennai

PostPosted: Mon Jul 23, 2007 5:09 pm
Reply with quote

Hai All,

While we write a record in RRDS, The relative record number is automatically generated, like first records as 1 and second record 2 and so on. But I want to start the RRN from 100 means how? Please help me...


With Regards

Rajesh.S
Back to top
View user's profile Send private message
William Thompson

Global Moderator


Joined: 18 Nov 2006
Posts: 3156
Location: Tucson AZ

PostPosted: Mon Jul 23, 2007 5:23 pm
Reply with quote

Probably the same way you would start a browse with a keyed file......
Back to top
View user's profile Send private message
Rajesh S
Warnings : 1

New User


Joined: 11 Jul 2007
Posts: 54
Location: Chennai

PostPosted: Mon Jul 23, 2007 5:30 pm
Reply with quote

Hai ,

Sorry I'm not getting you.. Please explain clearly....
Back to top
View user's profile Send private message
William Thompson

Global Moderator


Joined: 18 Nov 2006
Posts: 3156
Location: Tucson AZ

PostPosted: Mon Jul 23, 2007 5:41 pm
Reply with quote

Rajesh S wrote:
Sorry I'm not getting you.. Please explain clearly....
If you do not want to begin reading from the first record after an OPEN, you will need to START BRowsing at the RIDFLD you want......
Back to top
View user's profile Send private message
Rajesh S
Warnings : 1

New User


Joined: 11 Jul 2007
Posts: 54
Location: Chennai

PostPosted: Mon Jul 23, 2007 5:54 pm
Reply with quote

Hai ,

Thats not my problem. My problem is While write a record in new RRDS, RRN of that record is 1. RRN is automatically generated. Now I want to
Start the RRN as 100 for the first record means???

You understood my question???
Back to top
View user's profile Send private message
William Thompson

Global Moderator


Joined: 18 Nov 2006
Posts: 3156
Location: Tucson AZ

PostPosted: Mon Jul 23, 2007 5:58 pm
Reply with quote

You want to start writing a new dataset and have the first record in that dataset be RRN #100?
Or start re-writing an existing dataset at RRN #100?
Back to top
View user's profile Send private message
Rajesh S
Warnings : 1

New User


Joined: 11 Jul 2007
Posts: 54
Location: Chennai

PostPosted: Mon Jul 23, 2007 6:15 pm
Reply with quote

This is my question....

I want to start writing a new data set and have the first record in that dataset be RRN?
Back to top
View user's profile Send private message
Rajesh S
Warnings : 1

New User


Joined: 11 Jul 2007
Posts: 54
Location: Chennai

PostPosted: Mon Jul 23, 2007 6:17 pm
Reply with quote

I want RRN number start with 100....
Back to top
View user's profile Send private message
William Thompson

Global Moderator


Joined: 18 Nov 2006
Posts: 3156
Location: Tucson AZ

PostPosted: Mon Jul 23, 2007 6:25 pm
Reply with quote

You can't, not with a RRN file...you do realize that RRN satand for Relative Record Number, don't you? And that is relative to the beginning of the file, so the first record would always be #1 and the hundredth would always be #100........
Back to top
View user's profile Send private message
Rajesh S
Warnings : 1

New User


Joined: 11 Jul 2007
Posts: 54
Location: Chennai

PostPosted: Mon Jul 23, 2007 6:37 pm
Reply with quote

Thanks for your kind information... But i'm thinking that we can make the relative record number for starting record in the RRDS as user wish? And rest of the records are sequential 101,102,103.... so on..
Back to top
View user's profile Send private message
William Thompson

Global Moderator


Joined: 18 Nov 2006
Posts: 3156
Location: Tucson AZ

PostPosted: Mon Jul 23, 2007 6:42 pm
Reply with quote

Fine with me......
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8797
Location: Welsh Wales

PostPosted: Mon Jul 23, 2007 6:45 pm
Reply with quote

Why would you want to start from 100 ?

And if you think about the problem the solution is relatively easy.

But there again why not consider the use of an INDEXED file, such as a KSDS.
Back to top
View user's profile Send private message
Rajesh S
Warnings : 1

New User


Joined: 11 Jul 2007
Posts: 54
Location: Chennai

PostPosted: Mon Jul 23, 2007 6:55 pm
Reply with quote

But my question is We make the RRN start with 100 or not?

Is it possible....?????
Back to top
View user's profile Send private message
William Thompson

Global Moderator


Joined: 18 Nov 2006
Posts: 3156
Location: Tucson AZ

PostPosted: Mon Jul 23, 2007 6:59 pm
Reply with quote

No.

WRITE for relative files
For OUTPUT files, the WRITE statement causes the following actions:
v If ACCESS IS SEQUENTIAL is specified: The first record released has relative record number 1, the second record released has relative record number 2, the third number 3, and so on.
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


Joined: 23 Nov 2006
Posts: 19244
Location: Inside the Matrix

PostPosted: Mon Jul 23, 2007 8:14 pm
Reply with quote

Hello,

You need to use the technology as it is implemented - it will not change to meet some "user wish".

If your user wants to see things begin with 100 - fine, but you will have to provide that. A relative record number will not.
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 -> JCL & VSAM

 


Similar Topics
Topic Forum Replies
No new posts How to split large record length file... DFSORT/ICETOOL 10
No new posts SFTP Issue - destination file record ... All Other Mainframe Topics 2
No new posts FINDREP - Only first record from give... DFSORT/ICETOOL 3
No new posts Pulling a fixed number of records fro... DB2 2
No new posts Substring number between 2 characters... DFSORT/ICETOOL 2
Search our Forums:

Back to Top