IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

What is the maximum possible record length in COBOL


IBM Mainframe Forums -> COBOL Programming
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
Ganesh.Deokar

New User


Joined: 30 Sep 2005
Posts: 26
Location: Buffalo,NY

PostPosted: Mon Feb 19, 2007 11:09 am
Reply with quote

Hi,

I have a requirement to write the data in a single spanned record. For that I need to define the file with maximum record length.

Compiler limits in "COBOL/VSE Language Reference" says that in RECORD CONTAINS clause you can define upto 1,048,575 bytes, but SAM limits it to 32,767.

What is the maximum possible record length in COBOL?
Is there any way or special parameter in COBOL to achieve the above said maximum record length?

Thanks,
Ganesh
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


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

PostPosted: Mon Mar 05, 2007 7:48 am
Reply with quote

Hello,

Have you a solution for this yet?

Your limitation may well not be COBOL; please see this from the JCL manual:
Quote:
Lrecl
Specifies (1) the length, in bytes, for fixed length records or (2) the maximum length, in bytes, for variable-length records.
The value of bytes is:

1 to 32,760 for non-VSAM data sets.

1 to 32,761 for VSAM key-sequenced (KS), entry-sequenced (ES), or relative record (RR) data sets. (LRECL does not apply to VSAM linear space, RECORG=LS, data sets.)
Back to top
View user's profile Send private message
Ganesh.Deokar

New User


Joined: 30 Sep 2005
Posts: 26
Location: Buffalo,NY

PostPosted: Mon Mar 05, 2007 10:03 am
Reply with quote

I opted for LRECL=32760 and it's working.


Thanks..
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


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

PostPosted: Mon Mar 05, 2007 8:06 pm
Reply with quote

Thank you for posting your solution icon_smile.gif
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> COBOL Programming

 


Similar Topics
Topic Forum Replies
No new posts Store the data for fixed length COBOL Programming 1
No new posts How to split large record length file... DFSORT/ICETOOL 10
No new posts Replace each space in cobol string wi... COBOL Programming 3
No new posts PARSE Syntax for not fix length word ... JCL & VSAM 7
No new posts COBOL -Linkage Section-Case Sensitive COBOL Programming 1
Search our Forums:

Back to Top