Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

How to get RRN from RRDS file in CICS?

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
View previous topic :: :: View next topic  
Author Message
rajesh_mbt

New User


Joined: 27 Mar 2006
Posts: 95
Location: India

PostPosted: Fri Aug 05, 2011 7:08 am    Post subject: How to get RRN from RRDS file in CICS?
Reply with quote

Hi,
My requirement is to display records from a VSAM RRDS file along with corresponding RRN number based on some search field on the screen.

Eg: In CICS, Date is entered as search field, I need to retrieve the records starting from the date is being entered on the screen. Also, I need to display RRN of corresponding each records too on the screen.

How to retrieve the RRN number/what is the logic to implement?
Back to top
View user's profile Send private message

Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8057
Location: East Dubuque, Illinois, USA

PostPosted: Fri Aug 05, 2011 7:28 am    Post subject:
Reply with quote

Did you check the description of the RIDFLD and RRN options of the READ command in the CICS Application Programming Reference manual?
Back to top
View user's profile Send private message
rajesh_mbt

New User


Joined: 27 Mar 2006
Posts: 95
Location: India

PostPosted: Fri Aug 05, 2011 7:46 am    Post subject:
Reply with quote

Thanks for the response. Yes,I did read the reference manual but not sure on it since,could not find any sample logic over there.

So,just wanted explore many inputs from the forum to get some better idea icon_smile.gif
Back to top
View user's profile Send private message
enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10256
Location: italy

PostPosted: Fri Aug 05, 2011 1:17 pm    Post subject: Reply to: How to get RRN from RRDS file in CICS?
Reply with quote

Quote:
Eg: In CICS, Date is entered as search field, I need to retrieve the records starting from the date is being entered on the screen.

review Your wording and logic ...
A RRDS does not have a key, so to scan/search for some content pattern You will have to start always from the beginning

there is no logic to implement... just start reading records and compare the relevant fields

unless naturally You forgot to tell something important icon_evil.gif
Back to top
View user's profile Send private message
Bill Woodger

DFSORT Moderator


Joined: 09 Mar 2011
Posts: 7315

PostPosted: Fri Aug 05, 2011 3:43 pm    Post subject: Reply to: How to get RRN from RRDS file in CICS?
Reply with quote

And, to add the obvious, as you are sequentially processing the file to do any sort of "search", starting from the first record, you always have it within your power to know the RRN of the current or any other record that you feel like bothering with.

If you have a lot of records and are planning user-driver serial searches in CICS, I suggest you tear up what you have so far, start again, and do a bit more thinking this time.
Back to top
View user's profile Send private message
rajesh_mbt

New User


Joined: 27 Mar 2006
Posts: 95
Location: India

PostPosted: Sat Aug 06, 2011 12:35 am    Post subject: Re: Reply to: How to get RRN from RRDS file in CICS?
Reply with quote

enrico-sorichetti wrote:
Quote:
Eg: In CICS, Date is entered as search field, I need to retrieve the records starting from the date is being entered on the screen.

review Your wording and logic ...
A RRDS does not have a key, so to scan/search for some content pattern You will have to start always from the beginning

there is no logic to implement... just start reading records and compare the relevant fields

unless naturally You forgot to tell something important icon_evil.gif


Thanks for your reply. Thats what I wanted too, but what is the significance of the RIDFIELD when setting up startpoint anywhere in the file using STARTBR command. If that is the case how do I know the corresponding RRN value of the date is being searched.
Back to top
View user's profile Send private message
rajesh_mbt

New User


Joined: 27 Mar 2006
Posts: 95
Location: India

PostPosted: Sat Aug 06, 2011 12:38 am    Post subject: Re: Reply to: How to get RRN from RRDS file in CICS?
Reply with quote

Bill Woodger wrote:
And, to add the obvious, as you are sequentially processing the file to do any sort of "search", starting from the first record, you always have it within your power to know the RRN of the current or any other record that you feel like bothering with.

If you have a lot of records and are planning user-driver serial searches in CICS, I suggest you tear up what you have so far, start again, and do a bit more thinking this time.


Thanks Bill!! How do I get the RRN of corresponding each record, or the commands to get the RRN value?

This is what all I want to know.
Back to top
View user's profile Send private message
rajesh_mbt

New User


Joined: 27 Mar 2006
Posts: 95
Location: India

PostPosted: Sat Aug 06, 2011 12:46 am    Post subject:
Reply with quote

Hey All,
I found/understood that RIDFLD in READNEXT/READPREV command will give the RRN and INTO field wiill give the actul value of the record.

I was certainly not sure on this command and while reading and replying on this forum I understood cleary and slowly now!!!

Please correct me if still am wrong anything!!!!
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Converting Variable block file to Fix... bhavana yalavarthi DFSORT/ICETOOL 10 Tue May 16, 2017 2:20 pm
No new posts Getting error while opening a variabl... apandey1 COBOL Programming 5 Fri May 05, 2017 12:22 pm
No new posts Issue with NDM process to transmit ES... chetanambi All Other Mainframe Topics 6 Wed May 03, 2017 10:52 am
No new posts File processing vishwakotin Mainframe Interview Questions 9 Fri Apr 28, 2017 11:38 am
No new posts Occurrence of various strings within ... TS70363 JCL & VSAM 1 Thu Apr 27, 2017 8:18 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us