Page 1 of 1

What are work-files in SORT and are they mandatory?

Posted: Mon Jul 29, 2013 10:35 am
by Aseem_Forum
Hi,

What are work-files in SORT and are they mandatory for every SORT Job? What is importance of work files in the SORT utility?

Re: What are work-files in SORT and are they mandatory?

Posted: Mon Jul 29, 2013 6:15 pm
by Robert Sample
From the DFSORT Application Programming Guide manual:
A.1 Introduction When a sort application cannot be performed entirely in virtual storage, DFSORT must use work space. The amount of work space required depends on:
The amount of data being sorted
The amount of virtual storage available to DFSORT
The amount of Hiperspace available to DFSORT
The type of devices you use
The DFSORT functions and features you use (for example, VLSHRT, locale processing, EFS, and ALTSEQ can increase the amount of work space required).
There are three ways to supply work space for a DFSORT application:
Hiperspace
Dynamic allocation of work data sets
JCL allocation of work data sets.
A sort may not require work space at all -- it depends upon (a) how many records are to be sorted, and (b) how much memory is available to the system. If the sort requires work files, and they are not available in adequate number / size, the sort fails.

Re: What are work-files in SORT and are they mandatory?

Posted: Sat Aug 24, 2013 4:34 pm
by Aseem_Forum
Thanks Robert, this is helpful.