Joined: 10 Dec 2004 Posts: 110 Topics: 8 Location: Colorado USA
Posted: Mon Apr 04, 2005 12:40 pm Post subject:
Quote:
If your intention is only to empty the file , then you can Just delete the file and re allocate the file with the same name, this will create a empty file.
While this statement is correct if you intend to use this new "empty" file for OUTPUT later, allocation of a file in this way where you might open the file for input will cause you problems. This is because allocating the file does only that. It does not open the file and create and eof mark.
If you open a file for input that was allocated by an IEBR14, you will abend. It is even possible, though unlikely that you could end up processing data that just happened to be at that location on the disk.
________
hotels in mexico
Last edited by dtf on Tue Feb 01, 2011 1:52 pm; edited 1 time in total
Joined: 03 Dec 2002 Posts: 579 Topics: 1 Location: Iowa, USA
Posted: Mon Apr 04, 2005 1:00 pm Post subject:
Quote:
It does not open the file and create and eof mark.
This old dog recently learned a new trick. The latest versions of z/OS have changed the allocation logic such that even IEFBR14 datasets get a valid EOF marker! I imagine this was driven by security concerns of allocating over old data and readind it. _________________ Regards,
Bill Dennis
Disclaimer: My comments on this foorum are my own and do not represent the opinions or suggestions of any other person or business entity.
Joined: 26 Nov 2002 Posts: 12375 Topics: 75 Location: San Jose
Posted: Mon Apr 04, 2005 1:02 pm Post subject:
Quote:
This is because allocating the file does only that. It does not open the file and create and eof mark.
If you open a file for input that was allocated by an IEBR14, you will abend. It is even possible, though unlikely that you could end up processing data that just happened to be at that location on the disk.
Dtf,
IEFBR14 indeed sets the EOF MARK for SMS managed datasets.I am not sure about the non sms managed datasets.so is the case with IEBGENER
This has been discussed in length here (last 10 posts)
The disposition on SYSUT2 is OLD meaning the dataset is already existing and additional to that, you are specifying the DCB parameters. If your intention is that the dataset is already existing, remove the DCB parameters. If your intention is to create an empty dataset, use DISP=(NEW,CATLG,DELETE). _________________ I dont think I would ever stop learning. - Seshu.
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum