|
|
| Author |
Message |
muralithirumalaisamy Warnings : 1 New User
Joined: 13 Jun 2005 Posts: 10 Location: chennai
|
|
|
|
Can anyone help me on giving the commands in REXX to open, close and read a VSAM file.
Thanks
Murali |
|
| Back to top |
|
 |
References
|
|
 |
Aaru
Senior Member
Joined: 03 Jul 2007 Posts: 1136 Location: Mumbai - India
|
|
|
|
Murali,
| Quote: |
| Can anyone help me on giving the commands in REXX to open, close and read a VSAM file |
You cannot deal with VSAM datasets directly in REXX. You will have to REPRO the vsam file to a sequential dataset and do the EXECIO operations on it.
Also search this forum for VSAM for similar topics. |
|
| Back to top |
|
 |
superk
Moderator Team Head
Joined: 26 Apr 2004 Posts: 3265 Location: Charlotte,NC USA
|
|
| Back to top |
|
 |
agkshirsagar
Senior Member
Joined: 27 Feb 2007 Posts: 562 Location: Mumbai,India
|
|
| Back to top |
|
 |
Anuj D.
Global Moderator
Joined: 22 Apr 2006 Posts: 2159 Location: Phoenix, AZ
|
|
|
|
Hi,
I'm just starting with REXX. However, unless things have been changed recently, there isn't a way to do it with native REXX.
You may want to check out REXX/Tools by a company called Open Software Technologies
http://www.open-softech.com/
And as Aaru said, a simple solution is to use REPRO. This code reads on record from a VSAM parameter file. Somethinf like -
| Code: |
ADDRESS TSO ,
"ALLOCATE FILE(TEMPDD) NEW SPACE(1) TRACKS DSORG(PS) RECFM(F,B),
LRECL(139) BLKSIZE(27939)"
ADDRESS TSO ,
"REPRO INFILE("VSAM_file") OUTFILE("Seq_file") COUNT(1)"
ADDRESS TSO ,
"EXECIO 1 DISKR" Seq_file "(FINIS STEM Param_data." |
|
|
| Back to top |
|
 |
Garry Carroll
Active User
Joined: 08 May 2006 Posts: 166 Location: Dublin, Ireland
|
|
|
|
Try googling RXVSAM
Garry. |
|
| Back to top |
|
 |
dick scherrer
Global Moderator
Joined: 23 Nov 2006 Posts: 8643 Location: 221 B Baker St
|
|
|
|
Hello,
If your vsam file is large (say several million records), copying it to a qsam file just to make the data available to rexx sounds like a questionable (at best) idea. This will waste considerable system cycles as well as a bunch of dasd. . .
Maybe that data should not be processed by rexx directly? Maybe rexx could call some "service module" (cobol?) and read the necessary record(s) passing back the needed info to rexx. |
|
| Back to top |
|
 |
|
|