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
 

 

Variable File Length Method

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> COBOL Programming
View previous topic :: :: View next topic  
Author Message
swapnadeep.ganguly

Active User


Joined: 21 Mar 2007
Posts: 203
Location: India

PostPosted: Tue Nov 16, 2010 1:37 am    Post subject: Variable File Length Method
Reply with quote

Hi All,

Initially we had a program that used to handle 3 different files A,B,C with same DCB parameters as (LRECL=3004,RECFM=VB) in one particular COBOL program. The differnt files were used by 3 different JCL's referring the same COBOL program.

Now suddenly we are having 2 files A,B with new DCB parameters as (LRECL=4004,RECFM=VB) and the 3rd file with the old DCB i.e. (LRECL=3004,RECFM=VB).

Is is possible for us to handle this situation with the old COBOL program when the output file DCB remains unchanged? Or should we proceed to create a new program instead?

Your expert advices in this regards would be of great help.
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 Nov 16, 2010 3:27 am    Post subject:
Reply with quote

Hello,

One way is to consider 2 programs - one for the original dcb and another for the new. This may make maintenance/understanding easier.
Back to top
View user's profile Send private message
swapnadeep.ganguly

Active User


Joined: 21 Mar 2007
Posts: 203
Location: India

PostPosted: Tue Nov 16, 2010 4:36 am    Post subject:
Reply with quote

Hi,

We have that option. But is there no other way to handle this condition in the same program?
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: Tue Nov 16, 2010 5:29 am    Post subject:
Reply with quote

The new LRECL means you must add at least a DD statement and associated code to handle the file -- even though the files are all variable length, if the maximum record length in the COBOL program does not match the file LRECL, it will cause you problems.
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 -> COBOL Programming 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