How to access a VSAM?



IBM's Command List programming language & Restructured Extended Executor

How to access a VSAM?

Postby fazillatheef » Thu Aug 21, 2008 4:23 pm

How to access and process a VSAM file using REXX?
fazillatheef
 
Posts: 18
Joined: Mon Feb 25, 2008 12:50 pm
Has thanked: 0 time
Been thanked: 0 time

Re: How to access a VSAM?

Postby MrSpock » Thu Aug 21, 2008 5:08 pm

REXX doesn't support file I/O to/from VSAM datasets.
User avatar
MrSpock
Global moderator
 
Posts: 809
Joined: Wed Jun 06, 2007 9:37 pm
Location: Raleigh NC USA
Has thanked: 0 time
Been thanked: 4 times

Re: How to access a VSAM?

Postby Pedro » Thu Aug 21, 2008 10:18 pm

rexx does not provide support. But you can google for REXX VSAM and find external packages that do.
Pedro Vera
User avatar
Pedro
 
Posts: 686
Joined: Thu Jul 31, 2008 9:59 pm
Location: Silicon Valley
Has thanked: 0 time
Been thanked: 53 times

Re: How to access a VSAM?

Postby expat » Fri Aug 22, 2008 5:17 pm

It depends on the processing that you want to do.

You can use REPRO from inside REXX to retrieve a record of a KSDS by key, perform whatever task within the REXX, and then once more invoke IDCAMS to replace the record into the KSDS.
expat
 
Posts: 459
Joined: Sat Jun 09, 2007 3:21 pm
Has thanked: 0 time
Been thanked: 8 times

Re: How to access a VSAM?

Postby rlilley » Wed Sep 24, 2008 10:12 pm

Mark Winges' RXVSAM is available on the CBT FILE268.
I have used this for many years and am very happy with it. I would check it out.
rlilley
 
Posts: 3
Joined: Wed Sep 24, 2008 10:04 pm
Has thanked: 0 time
Been thanked: 0 time

Re: How to access a VSAM?

Postby Jikesh Patel » Tue Dec 01, 2009 7:18 pm

Hello,

expat wrote:
You can use REPRO from inside REXX to retrieve a record of a KSDS by key, perform whatever task within the REXX, and then once more invoke IDCAMS to replace the record into the KSDS.


You mean to say to write the command:
ADDRESS TSO ,
"REPRO INFILE("VSAM_file") OUTFILE("Seq_file") COUNT(1)"
And then open a seq_file?

But how to edit the vsam record and save on the same VSAM file?
Jikesh Patel
 
Posts: 23
Joined: Mon Apr 06, 2009 12:41 pm
Has thanked: 0 time
Been thanked: 0 time

Re: How to access a VSAM?

Postby MrSpock » Tue Dec 01, 2009 7:39 pm

I think that question was already answered.

Why would you WANT to do such a process with REXX when there are other languages much better suited to this?
User avatar
MrSpock
Global moderator
 
Posts: 809
Joined: Wed Jun 06, 2007 9:37 pm
Location: Raleigh NC USA
Has thanked: 0 time
Been thanked: 4 times

Re: How to access a VSAM?

Postby Jikesh Patel » Thu Dec 03, 2009 12:09 am

Thanks MrSpock,

REXX is used to make automat the processes so if we create REXX utility to copy a VSAM file to new VSAM file with same attribute. This is maily used to dump one regiion to other like production region to test region.

The same thing we can do by JCL but for that we have to run that JCL for every vsam file.

I am sure I will get very good suggestions for doing this.

Thanks,
-jd patel
Jikesh Patel
 
Posts: 23
Joined: Mon Apr 06, 2009 12:41 pm
Has thanked: 0 time
Been thanked: 0 time

Re: How to access a VSAM?

Postby dick scherrer » Thu Dec 03, 2009 4:17 am

Hello,

One of the best suggestions you will receive is that this is not a job for rexx. It is a job that should be run in a batch process. The batch process will probably be repeated many times, so there is a small investment to create the initial job(s) and then it is only a matter of running them.

If you want something more automated, you could condiser using rexx to create the batch jcl to be submitted. . .
Hope this helps,
d.sch.
User avatar
dick scherrer
Global moderator
 
Posts: 6268
Joined: Sat Jun 09, 2007 8:58 am
Has thanked: 3 times
Been thanked: 93 times

Re: How to access a VSAM?

Postby expat » Thu Dec 03, 2009 12:57 pm

And it is untrue that you would need to run a Batch Job (NOT JCL) for every VSAM file.

Have you not looked at DFdss or even better if it is installed, FAVER.

You use ONE job to dump on the prod LPAR and ONE job to restore on the other LPAR
expat
 
Posts: 459
Joined: Sat Jun 09, 2007 3:21 pm
Has thanked: 0 time
Been thanked: 8 times

Next

Return to CLIST & REXX

 


  • Related topics
    Replies
    Views
    Last post