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 open a (+0) or (-1) generation of a file thru REXX?

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CLIST & REXX
View previous topic :: :: View next topic  
Author Message
dvpkumar217

New User


Joined: 01 Sep 2007
Posts: 11
Location: Baltimore, MD US

PostPosted: Tue Sep 11, 2007 2:20 am    Post subject: How to open a (+0) or (-1) generation of a file thru REXX?
Reply with quote

My requirement is to open a file which is coded in the format:
(Userid).TEST.TEMP(-n). Where n can vary from 0 to any number.

Can we accomplish this task thru REXX or TSO cmd?
Back to top
View user's profile Send private message

dick scherrer

Site Director


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

PostPosted: Tue Sep 11, 2007 3:10 am    Post subject:
Reply with quote

Hello,

I believe you need to first convert your "relative" generation to the absolute dataset name (Userid.TEST.TEMP.GnnnnVnn) and open that.
Back to top
View user's profile Send private message
superk

Moderator Team Head


Joined: 26 Apr 2004
Posts: 4648
Location: Raleigh, NC, USA

PostPosted: Tue Sep 11, 2007 6:54 am    Post subject: Reply to: How to open a (+0) or (-1) generation of a file th
Reply with quote

Yep.

REXX reads only from DD names. If you run the REXX in batch, you can define the DD and GDG in your JCL, and then read from it or write to it with EXECIO.

A referral to a GDG by relative generation number is strictly a JCL construct.
Back to top
View user's profile Send private message
mguolo

New User


Joined: 23 Jun 2006
Posts: 1

PostPosted: Wed Sep 12, 2007 8:22 pm    Post subject: Reply to: How to open a (+0) or (-1) generation of a file th
Reply with quote

You can do it inside the rexx program thru the LISTCAT tso command and put the result in a stem, after this you can get the name of your dataset name and then allocate it thru the ALLOCATE command.
icon_lol.gif
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 -> CLIST & REXX All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Changing of LRECL of a file abdulrafi DFSORT/ICETOOL 2 Fri Mar 24, 2017 3:25 pm
No new posts splitting a file abdulrafi DFSORT/ICETOOL 3 Fri Mar 24, 2017 11:51 am
No new posts Receive a file using PCOMM macro Harald.v.K IBM Tools 0 Thu Mar 23, 2017 6:50 pm
No new posts Export flat file data into excel sheet murali.andaluri DFSORT/ICETOOL 2 Mon Mar 20, 2017 5:39 pm
No new posts Formatting VB File Learncoholic DFSORT/ICETOOL 3 Mon Mar 20, 2017 12:29 pm


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