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
 
"RECORD VARYING FROM" Clause

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

New User


Joined: 30 May 2006
Posts: 7

PostPosted: Wed Jul 12, 2006 11:48 am    Post subject: "RECORD VARYING FROM" Clause
Reply with quote

Hi .

In case of having variable length record we can use
"RECORD VARYING FROM" Clause but in that case the maximum
record length will be considered.

But what if we have different files with different record length ??
i.e I may have file with maximum record length say 1000 at some
instant while same file might have maxi record length say 5000 ...

So is there any way i can get the file attributes (i.e maximum record
length etc) in the prog at run time ??
Back to top
View user's profile Send private message

nagae

New User


Joined: 17 May 2005
Posts: 1

PostPosted: Wed Jul 12, 2006 12:44 pm    Post subject:
Reply with quote

Hi ,

See below statement ..
input-file
BLOCK 0
RECORDING MODE V
RECORD VARYING FROM 1 TO 4092 DEPENDING ON W00-IN-REC-LEN.

When ever u excute read para, the lenth of the record will be stored in W00-IN-REC-LEN variable.

u have to decalre that varibale in working stoarge section as mentioned below.

W00-IN-REC-LEN PIC 9(9) BINARY.

Regards
nagae
Back to top
View user's profile Send private message
bhavishya_bhandari

New User


Joined: 30 May 2006
Posts: 7

PostPosted: Wed Jul 12, 2006 2:52 pm    Post subject: Re: Varying Record Length ...
Reply with quote

Ok ...
fine just lemme knw that is there any way either thru COBOL or thru JCL by which I can knw the input file(Flat-File) Attributes (viz Record Length etc ..) during run time in the Program ...
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
This topic is locked: you cannot edit posts or make replies. Extract all "IF" Statements... Adarsh Damodaran CLIST & REXX 1 Wed Sep 06, 2017 9:28 am
No new posts Updating the Trailer count in variabl... satheshbabur DFSORT/ICETOOL 6 Wed Aug 30, 2017 9:49 pm
No new posts Repeat part of record multiple times Learncoholic DFSORT/ICETOOL 4 Tue Aug 29, 2017 11:33 am
No new posts Read two inputs and write into output... murali.andaluri DFSORT/ICETOOL 6 Wed Jul 26, 2017 7:35 pm
No new posts Changeman get multiple "Browse C... elixir1986 Compuware & Other Tools 4 Fri Jul 14, 2017 1:48 am

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