For Programmers: Free Programming Magazines  


Home > Archive > Cobol > April 2007 > Re: COBOL dynamic allocation (putenv) of output-file won't release extra space when c









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Re: COBOL dynamic allocation (putenv) of output-file won't release extra space when c
miguel.laiz@gmail.com

2007-04-25, 3:55 am

On 12 Mar, 18:08, "William M. Klein" <wmkl...@nospam.netcom.com>
wrote:
> I am checking with some IBM sources on this, but one POSSIBLE solution would be
> to use an SMS storage class that automatically does what you want. (I think SMS
> can handle RLSE - but I *know* it can put your dataset on "temporary" storage)
>
> --
> Bill Klein


Hi Bill K,

first of all, my apologies for taking so long to comment on your
feedback. Long overdue vacation and trying deadlines came between my
initial question.

So far, I've managed to get the file I create to be BLOCKED by adding
the BLOCK CONTAINS 0 CHARACTERS clause in the program to the FD
descriptor.

I know that all the file attributes could probably be managed through
SMS and STORCLAS, MGMTCLAS and DATACLAS keywords. The documentation
says that they are supported. And that is what your answer, Bill, also
mentions. My problem is that the client I'm currently working for has
added a coupling between the second level in the DSN-name and a
MANAGEMENT class. So for example P211.DEL1.ABCD would create a file
that expires after 31 days and is deleted. In this example could be
DELx where x represents different expiry dates. I fully understand
that this is shop dependant.

The problem is that I can't seem to specify a DSN-name and also a
DATACLAS attribute in the string used as data with my environment-
variable to create a file. It is totally ignored. I thought that
DATACLAS would override it somehow. In the long run if I want to play
by the shop rules the only way might be to create a new set of DSN-
name levels (as
DEL in the example) but all have the BLOCKING set and the RELEASE of
unused allocated space.



I'm thinking of maybe calling using IKJTSOEV and then IKJEFTSR with a
ALLOC and FREE would be another way to go. I think there is BLOCK and
RLSE keywords that would let me save a lot of space when creating
small and large datasets.

Any thoughts, anyone?

Cheers
Miguel

Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com