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
 

 

How to rewrite record in variable length sequential file?

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

New User


Joined: 21 Sep 2008
Posts: 4
Location: pune

PostPosted: Sun Apr 03, 2011 11:54 am    Post subject: How to rewrite record in variable length sequential file?
Reply with quote

Hi,

I have one sequential file with variable length.
I want to update that file.
So I am using rewrite statement.
But at the time of execution it is giving abend.
& there is file error at rewrite statement i.e. file status is 44.
44 : Rewrite attempt with invalid length.
Back to top
View user's profile Send private message

prino

Senior Member


Joined: 07 Feb 2009
Posts: 1018
Location: Oostende, Belgium

PostPosted: Sun Apr 03, 2011 4:40 pm    Post subject:
Reply with quote

And what is your problem?
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Sun Apr 03, 2011 6:06 pm    Post subject:
Reply with quote

Well, with so much information at hand it's so very hard to know where to start.

What is the DSORG of the file.
Are you writing longer than the original record.
DCB attributes of the file.
File is on which media.
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: Sun Apr 03, 2011 7:08 pm    Post subject:
Reply with quote

Not to mention -- which abend code did you get?

You basically tell us nothing and expect us to psychically read your mind to know these details?
Back to top
View user's profile Send private message
Nic Clouston

Global Moderator


Joined: 10 May 2007
Posts: 1788
Location: UK

PostPosted: Sun Apr 03, 2011 7:28 pm    Post subject:
Reply with quote

Remember - if you are to rewrite a record it must be of the same length as the original record as it has to fit in the same space as it was read from.
Back to top
View user's profile Send private message
kapiltamrakar

New User


Joined: 24 May 2009
Posts: 41
Location: Hyderabad

PostPosted: Mon Apr 04, 2011 2:15 pm    Post subject:
Reply with quote

can you please provide the FD section of that file and the copybooks / record lengths that are used for that file along with the record length which you are trying to rewrite while getting abend.
( I guess there must be 2-3 different kind of records are getting written in th same file that make it varuable length.)
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: Mon Apr 04, 2011 2:45 pm    Post subject:
Reply with quote

Quote:
(I guess there must be 2-3 different kind of records are getting written in th same file that make it varuable length.)
Or it could be an OCCURS DEPENDING ON -- the other way of creating variable length records.
Back to top
View user's profile Send private message
kapiltamrakar

New User


Joined: 24 May 2009
Posts: 41
Location: Hyderabad

PostPosted: Mon Apr 04, 2011 2:53 pm    Post subject:
Reply with quote

Hi Robert,
well said... icon_smile.gif thanks for adding point missed by me... icon_smile.gif

Regards,
Kapil.
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 Adding big TEXT lines to each record ... bshkris SYNCSORT 4 Sat May 06, 2017 1:40 am
No new posts Getting error while opening a variabl... apandey1 COBOL Programming 5 Fri May 05, 2017 12:22 pm
This topic is locked: you cannot edit posts or make replies. Merge two files and update Trailer re... Yashashri JCL & VSAM 1 Thu May 04, 2017 12:54 pm
No new posts Issue with NDM process to transmit ES... chetanambi All Other Mainframe Topics 6 Wed May 03, 2017 10:52 am


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us