Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
How to convert VSAM file to Flat file (PS File)

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> PL/I & Assembler
View previous topic :: :: View next topic  
Author Message
afroz alam

New User


Joined: 02 Jul 2007
Posts: 13
Location: India

PostPosted: Tue Jan 25, 2011 11:35 pm    Post subject: How to convert VSAM file to Flat file (PS File)
Reply with quote

I want to convert VSAM file to PS file. The record size of VSAM file is 60520. When i tried to convert this through JCL (using IDCAMS) by providing DCB parameter (LRECL=60520,RECFM=VB,BLKSIZE=0), it gives JCL error saying 'LRECL is too large'. I think it is because of LRECL should be max of 32768.

Can we do this through any programs or utility? How to convert VSAM of recordsize 60520 into PS File?

I have seen so may documents for this, all are mentioned this throgh IDCAMS but their record size was less. so there was no problem. But nowhere mentioned if the record size is bigger, then how to convert.

Thanks for the help in advance.

Thanks
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: Wed Jan 26, 2011 12:49 am    Post subject:
Reply with quote

Hello,

Write a bit of code or use a utility to split the large vsam records into multiple smaller records.
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


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

PostPosted: Wed Jan 26, 2011 12:51 am    Post subject:
Reply with quote

From the Access Method Services for Catalogs manual on the DEFINE CLUSTER record size:
Quote:
Restriction: With REPRO and EXPORT, you cannot use data sets with record sizes greater than 32 760.
So you can either (1) manually figure out how to split the VSAM records into records of no more than 32760 bytes so you can copy the VSAM file to a sequential file, or (2) give up on the idea of dumping the VSAM file to a sequential file. Your choice.
Back to top
View user's profile Send private message
Ronald Burr

Active User


Joined: 22 Oct 2009
Posts: 293
Location: U.S.A.

PostPosted: Wed Jan 26, 2011 1:02 am    Post subject:
Reply with quote

I've never tried it, but (if I interpret the JCL manual correctly) you "might" be able to use RECFM=VS (no B), with LRECL=X, and a BLKSIZE that is NOT equal to zero (suggest a BLKSIZE of just less than a half track for dasd, or 32760 for tape )

Worth a try?

Of course, the larger question remains - what is the purpose for copying the VSAM file to a PS file in the first place?
Is it just for "backup" purposes (if so, there are MUCH better ways to do it).
Will the output file be used as input to another process? If so, how will the recipient program handle such a large LRECL?
Back to top
View user's profile Send private message
afroz alam

New User


Joined: 02 Jul 2007
Posts: 13
Location: India

PostPosted: Wed Jan 26, 2011 10:40 pm    Post subject: Reply to: How to convert VSAM file to Flat file (PS File)
Reply with quote

Thanks to all for the response......

@Ronald Burr - I tried with VS with BLKSIZE=0, it did notwork...I will try with BLKSIZE not equal to zero. Will let you know.

As per your question, yes, VSAM to PS file is required as it will be used by another system to read it.

Once again, Thanks to All....
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: Wed Jan 26, 2011 10:47 pm    Post subject:
Reply with quote

Hello,

Quote:
VSAM to PS file is required as it will be used by another system to read it.
You need to consider how to split the records so the other system will be able to read the data. . .

Or simply create another vsam file for that system to read. . .
Back to top
View user's profile Send private message
PeterHolland

Global Moderator


Joined: 27 Oct 2009
Posts: 2445
Location: Netherlands, Amstelveen

PostPosted: Wed Jan 26, 2011 11:23 pm    Post subject:
Reply with quote

The TS could look at LRECL=X, BFTEK=A, RECFM=VBS
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 -> PL/I & Assembler All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts ISSUE IN copying Sequential file reco... thesumitk JCL & VSAM 2 Wed Dec 13, 2017 3:07 pm
No new posts File Tailoring -- Temporary dataset i... samzee71 CLIST & REXX 3 Fri Dec 01, 2017 3:12 am
No new posts Rexx - File tailoring samzee71 CLIST & REXX 10 Thu Nov 30, 2017 10:47 pm
No new posts Compare VSAM files using DFSORT pshongal DFSORT/ICETOOL 5 Thu Nov 23, 2017 10:24 am
No new posts Moving a PS file as body of a mail! Vignesh Sid JCL & VSAM 4 Tue Nov 21, 2017 9:23 pm

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us