By using a combination of SFLSIZ and SFLPAG you indicate whether the subfile is a load all, self-extending or page at a time subfile.
There is an excellent tutorial on subfiles by Kevin Vandever here;
SFLSIZ determines how much memory is allocated when you open your display file. When SFLSIZ is greater than SFLPAG, the system is allowed to increase the memory allocation whenever you add subfile records beyond the capacity of the current allocation.
For a load-all (or an expanding) subfile, this means that you don't need to be concerned about how many subfile records you create until you reach the physical limit of 9999 subfile records.
The system recognizes the special case of SFLSIZ equal to SFLPAG. The memory allocation never changes. This is the special case of a page-at-a-time subfile.
The best value for SFLSIZ should be enough to handle maybe 80% of all requests. If you know that there will always be, say, 100 subfile records, then it simply wastes system CPU resources when you specify SFLSIZ less than 100.
There has been a historical practice of specifying SFLSIZ to be SFLPAG+1. The only reasons for it are that it's easy to do and easy to remember.
Last Wiki Answer Submitted: May 4, 2010 6:58 am by Sloopy2,195 pts.