Defines reports and their attributes.
DECLARE-REPORT report_name [TOC=toc_name] [LAYOUT=layout_name] [PRINTER-TYPE=printer_type] END-DECLARE
Name of the Table of Contents.
Layout name. If none is specified, the default layout is used.
Type of printer. If none is specified, the default is the LINEPRINTER. If no DECLARE‑PRINTER is specified, DEFAULT-LP is used. Valid values for PRINTER-TYPE are HT, HP, PD, PS, LP, HTML, HPLASERJET, POSTSCRIPT, and LINEPRINTER.
Issue DECLARE-REPORT in the SETUP section.
You can use DECLARE-REPORT to declare one or more reports to be produced in the application.
You must use this command when developing applications to produce more than one report.
Multiple reports can share the same layout and the same printer declarations or each report can use its own layout or printer definitions if the report has unique characteristics.
When you are printing multiple reports, unless report names are specified using the -F command-line flag, the first report declared is generated with the name of program.lis, where program is the application name.
Additional reports are generated with names conforming to the rules dictated by the SQR.INI OUTPUT-FILE-MODE setting.
When the -KEEP or -NOLIS flags are used, the first intermediate print file (SPF file) is generated with a name of program.spf and additional reports are generated with names conforming to the rules dictated by the SQR.INI OUTPUT-FILE-MODE setting.
declare-report customer_detail toc=detailed layout=customer_layout printer-type=postscript end-declare
declare-report customer_summary layout=summary_layout printer-type=postscript end-declare . . . use-report customer_detail ...print customer detail... use-report customer_summary ...print customer summary...
USE-REPORT, DECLARE-LAYOUT, DECLARE-PRINTER, and DECLARE-TOC