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
 

 

File contents cleared on abend

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
View previous topic :: :: View next topic  
Author Message
senthil1kumar

New User


Joined: 20 May 2008
Posts: 5
Location: bangalore

PostPosted: Thu Jul 17, 2008 5:08 pm    Post subject: File contents cleared on abend
Reply with quote

Hi, Below is my scenario. Please let me know your thoughts,

1)Iam writing to a output file(existing) in a program with DISP=SHR
2)Opening the file in OUTPUT mode.
3)Few records have been written successfully.
4)then program abends
5)When i check the output file i dont see any records in it.

Since i have given DISP=SHR, successful records should be present in the file right?

Please let me know if I am missing anything.

Thank you!!
Back to top
View user's profile Send private message

Craq Giegerich

Senior Member


Joined: 19 May 2007
Posts: 1512
Location: Virginia, USA

PostPosted: Thu Jul 17, 2008 5:12 pm    Post subject:
Reply with quote

It would depend on the number of records you have written, the blocksize of the file, and the number of buffers used for the file. Incase of an abend don't count on any of the output being complete or useable.
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: Thu Jul 17, 2008 5:13 pm    Post subject:
Reply with quote

Your few records may have been written to a buffer rather than the hardware device.
Back to top
View user's profile Send private message
Prasanthhere

Active User


Joined: 03 Aug 2005
Posts: 306

PostPosted: Thu Jul 17, 2008 5:23 pm    Post subject: Reply to: File contents cleared on abend
Reply with quote

Unless you have a restart logic implemented its not necessary that many records needs to wrritten into the o/p file
Back to top
View user's profile Send private message
senthil1kumar

New User


Joined: 20 May 2008
Posts: 5
Location: bangalore

PostPosted: Thu Jul 17, 2008 5:33 pm    Post subject:
Reply with quote

Craq Giegerich wrote:
It would depend on the number of records you have written, the blocksize of the file, and the number of buffers used for the file. Incase of an abend don't count on any of the output being complete or useable.


thanks for your lightening response icon_smile.gif

- its a report file of rejected records.
-we have a checkpoint-restart logic invoved. So after an abend, file would be opened with DISP=MOD so that records are appended to it.
- Hence, It would not be valid to proceed with the restart if old records are not present in the file.

Would it be useful if i explicitly close the file before calling abend routine. Maybe that would write the records from buffer to physical file?

thanks!
Back to top
View user's profile Send private message
senthil1kumar

New User


Joined: 20 May 2008
Posts: 5
Location: bangalore

PostPosted: Thu Jul 17, 2008 5:54 pm    Post subject:
Reply with quote

expat wrote:
Your few records may have been written to a buffer rather than the hardware device.


Would it be useful if i explicitly close the file before calling abend routine. Maybe that would write the records from buffer to physical file?
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: Thu Jul 17, 2008 11:06 pm    Post subject:
Reply with quote

Hello,

Quote:
Would it be useful if i explicitly close the file before calling abend routine.
If this is a controlled abend, yes - closing the file before calling the abend routine would be a good idea.
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 -> JCL & VSAM All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts SORTJOIN - Copy Matched and Unmatched... Steve Ironmonger DFSORT/ICETOOL 5 Tue Jan 17, 2017 4:26 pm
No new posts Copy RECFM =VB TO FB file with RECL =... sahil41352 DFSORT/ICETOOL 3 Wed Dec 28, 2016 11:29 pm
No new posts Add PD field from 2nd file to PD in 1st Sushant Garje DFSORT/ICETOOL 6 Thu Dec 01, 2016 4:32 pm
No new posts File Aid to File Manager conversion murali3955 IBM Tools 4 Thu Nov 24, 2016 3:41 pm
No new posts IMS BMP program causes 878 system abend Artemk IMS DB/DC 7 Tue Nov 22, 2016 8:26 pm


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