Temporary REPORT work files should be used instead of temporary EZTVFM virtual files if you are writing out multiple reports, or large sequenced reports, or even huge reports because EZTVFM data sets can't span disk packs. Also, you could gain a performance improvement by using REPORT workfiles.
There is a "Large Reports" chapter in the CA Easytrieve Programming Guide. It states, if you have multiple large reports in a program, you can code the WORKFILE YES parameter on the PARM statement or set the WORKFILE site option to Y. This allows you to use a report work file without coding a FILE statement and a FILE parameter on the REPORT statement for every report in your program. REPORT WORKFILEs are dynamically allocated, no DD statements are required to be coded in the JCL.
For instance, if you would like to do it manually, you have to add DD statements to your JCL:
//EZTR001 DD UNIT=SYSDA,SPACE=(CYL,(1000,1000)) or whatever space you need
//EZTR002 DD UNIT=SYSDA,SPACE=(CYL,(1000,1000)) or whatever space you need
and so on depending on the number of reports your program generates.
In order to determine the record length for the workfiles, first run the program without the workfiles. You can add an
IF RECORD-COUNT GT 1000
statement to your program making the number of records great enough to write out at least one record to each report.
After the run, look at the file statistics for EZTR00n report workfiles. REPORT 1 gets spooled to EZTR001, REPORT 2 gets spooled to EZTR002, etc.
For each file, you should see the VFM record length (LRECL). This is the length you should specify for each of your report workfiles.
In this example, the EZTR001 file had an LRECL of 60, so this is what was specified for EZTR001.
EZTR002 had an LRECL of 42, therefore EZTR002 has an LRECL of 42.
The only other way to get the LRECL for the report workfile is to add up the lengths of ALL "W" type working storage file fields used in the REPORT section.
If your program only creates one report and it does NOT have a SEQUENCE statement, we do real time printing of the report and are not spooling data to the EZTVFM.
If your program creates two or more reports and none of the reports have a SEQUENCE statement, we will do real time printing of the first report and any subsequent reports will spool to EZTVFM.
If the first report has a SEQUENCE statement, all will spool to EZTVFM.
PRINTER files are NOT the same thing as report workfiles.