Hi,
Actually my problem is that in my job the input dataset is having varying number of records.Sometimes it comes to 100,sometimes 10000,means its varying.But the problem is when I am specifying the space parameters it will abend as I am not sure about the number of records.
So,Is there any way to optimize this like depending upon the number of records it will allocate space(apart from RLSE parameter).
Thanks and Regards
Sandeep.
Space problem in JCL
Moderators: Frank Yaeger, DikDude, Moderator Group
Hi Sandeep,
I dont think so there is a way by which the system calcualtes the space
by itself based on the no of recs in the I/P file.
Well, you have any issue with the RLSE parameter anyhow the memory
gets released correct...no matter how much you specify.
Otherwise you can go for Tapes...if you have an option ...
Lets see if some one responds and if there is a dynamic way of calculating the space as you have asked for...it would be good to know.
Thanks,
Veera.
I dont think so there is a way by which the system calcualtes the space
by itself based on the no of recs in the I/P file.
Well, you have any issue with the RLSE parameter anyhow the memory
gets released correct...no matter how much you specify.
Otherwise you can go for Tapes...if you have an option ...
Lets see if some one responds and if there is a dynamic way of calculating the space as you have asked for...it would be good to know.
Thanks,
Veera.
Sandeep,
Will you know the number of records prior to allocation? There may be some overrides if you do know.
But allocating sufficient, but not to much space if the function of the 'RLSE' keyword. Allocate for the max and then release unused space upon closing.
You can also try to allocate space using extents.
SPACE=(recsz,(prim alloc, second alloc),RLSE),AVGREC=U
Where
LRECL=200
recsz = your LRECL
prim alloc = average number of records
second alloc = 1/14 (max number of records ? average number of records)
lets say the average number of records you will be allocating for is 2500 and the max number of records that you will allocate is 100,000.
Then the allocation might look like
SPACE=(200,(2500,6965),RLSE),AVGREC=U,
RECFM=FB,LRECL=200
Where prim alloc is for space for 2500 records of LRECL=200
And the secondary alloc will be for up to 14 allocations of space for 6965 records for LRECL=200
2500 + (6965 * 14) = 100,010 records
Will you know the number of records prior to allocation? There may be some overrides if you do know.
But allocating sufficient, but not to much space if the function of the 'RLSE' keyword. Allocate for the max and then release unused space upon closing.
You can also try to allocate space using extents.
SPACE=(recsz,(prim alloc, second alloc),RLSE),AVGREC=U
Where
LRECL=200
recsz = your LRECL
prim alloc = average number of records
second alloc = 1/14 (max number of records ? average number of records)
lets say the average number of records you will be allocating for is 2500 and the max number of records that you will allocate is 100,000.
Then the allocation might look like
SPACE=(200,(2500,6965),RLSE),AVGREC=U,
RECFM=FB,LRECL=200
Where prim alloc is for space for 2500 records of LRECL=200
And the secondary alloc will be for up to 14 allocations of space for 6965 records for LRECL=200
2500 + (6965 * 14) = 100,010 records
FREE TUTORIALS
Tutorials
Free tutorials from mainframegurukul
- JCL Tutorial
Covers all important JCL concepts. - Cobol Tutorial
This tutorials covers all Cobol Topics from STRING to COMP-3. - DB2 Tutorial
DB2 Tutorial focuses on DB2 COBOL Programming. - SORT Tutorial
This Tutorial covers all important aspects of DFSORT with examples - CICS Tutorial
This CICS tutorial covers CICS concepts and CICS Basics, CICS COBOL Programming.
Interview
Mainframe Interview questions
- Cobol Interview Questions
50+ Interview Questions - JCL Interview Questions
50+ Interview Questions - DB2 Interview Questions
100+ Interview Questions - CICS Interview Questions
70+ Interview Questions - VSAM Interview Questions
27 Interview Questions
Other References
Mainframe Tools and others
- XPEDITER Reference
Explains how we can debug a program - FILEAID Reference
Explains how to browse , edit and delete datasets - Change Man Reference
Quick Start tutorial on Changeman - Abend Reference
Important Abend codes explained - FaceBook Page
MainframeGurukul FaceBook Page - LinkedIn Page
MainframeGurkul Linkedin Page