Use the FORM.BREAKn panels to make choices about the text and its placement for up to six breaks in a report. QMF places that text after its associated break in the report.
FORM.BREAKn does not affect charts.
Specify a break usage code in the USAGE entry area ( B ) on FORM.MAIN or FORM.COLUMNS opposite one of the column names (see pages FORM.MAIN and FORM.COLUMNS). That column then becomes the control column and a break occurs in the report whenever the value in this control column changes.
When evaluating values in VARCHAR columns, QMF differentiates between a value padded with blanks or hexadecimal zeros and the same values without these trailing characters. Using FORM.BREAKn in such cases creates a break.
You can use the same level of break on multiple columns. In this case, a break occurs when a value changes in any one of those columns.
Area I on FORM.MAIN specifies footing text for BREAK1 and BREAK2 in a report and whether to start a new page each time the value in the control column changes. Whatever you specify in area I of FORM.MAIN is reflected on FORM.BREAK1 and FORM.BREAK2. What you specify on areas H and N on BREAK1 and BREAK2 is reflected on FORM.MAIN.
There are six FORM.BREAKn panels -- one for each possible level of break. They are all the same, except for the panel title.
FORM.BREAK1 A New Page for Break? ===> NO B Repeat Detail Heading? ===> NO C Blank Lines Before Heading ===> 0 D Blank Lines After Heading ===> 0 E LINE F ALIGN G BREAK1 HEADING TEXT ---- ------ ----+----1----+----2----+----3----+----4----+----5----+ 1 LEFT 2 LEFT 3 LEFT *** END *** H New Page for Footing? ===> NO I Put Break Summary at Line ===> 1 J Blank Lines Before Footing ===> 0 K Blank Lines After Footing ===> 1 L LINE M ALIGN N BREAK1 FOOTING TEXT ---- ------ ----+----1----+----2----+----3----+----4----+----5----+ 1 RIGHT 2 RIGHT 3 RIGHT *** END *** 1=Help 2=Check 3=End 4=Show 5=Chart 6=Query 7=Backward 8=Forward 9= 10=Insert 11=Delete 12=Report OK, FORM.BREAK1 is displayed. COMMAND ===> SCROLL ===> PAGE
Specifying YES for more than one break level can produce more pages than expected in your printed or exported report. This happens when multiple breaks occur at the same time.
If you specify two or more breaks and also specify YES for New page for break on each break, a page is generated for each specified break whenever the highest break level occurs. Multiple breaks frequently occur together, since the highest break level forces all lower break levels to occur. In particular, all breaks occur for the first row of data in a report.
In printed reports, if a break begins at the top of a page and you specify YES, only one set of detail headings appears.
Detail headings consist of the detail heading text specified on the FORM.DETAIL panel, plus column headings (unless you suppress column headings on the FORM.DETAIL panel). See FORM.DETAIL.
Specifying YES for Repeat Detail Headings on FORM.DETAIL overrides the specifications given here.
The numbers you choose need not start with 1 or be consecutive.
For example, these values on FORM.BREAK1:
LINE ALIGN BREAK1 HEADING TEXT ---- ----- ------------------- 3 LEFT DEPARTMENT &4 2 LEFT BEGINNING OF LISTING
display as:
BEGINNING OF LISTING DEPARTMENT 35
Notice that a blank line appears before the first line of text.
The appended line of text must have the same LINE value as the line of text it is being appended to. If the report is not wide enough to accommodate the appended line of text, some of the text might be truncated.
For example, the following entries on FORM.BREAK1:
Blank Lines Before Heading ===> 0 LINE ALIGN BREAK1 HEADING TEXT ---- ------ ---------------------- 1 LEFT DEPARTMENT 1 APPEND &4 3 LEFT
align the columns in the resulting report as shown:
DEPT COMM JOB SALARY ------ ---------- ----- ---------- DEPARTMENT 66 66 55.50 CLERK 10988.00 - MGR 18555.50 844.00 SALES 16858.20 200.30 SALES 21000.00 811.50 SALES 18674.50 ---------- * 86076.20 DEPARTMENT 84 84 188.00 CLERK 13030.50 - MGR 19818.00
If your installation supports DBCS data, see Names with double-byte characters.
By default, break heading text extends from the left to the right margin of a report. However, you can choose the width of break heading text on the Report text line width entry on FORM.OPTIONS (see pageFORM.OPTIONS).
To make the break heading text appear in a report in uppercase and lowercase, specify in your profile a CASE value of either STRING or MIXED.
Break heading text can contain the following variables:
BEGINNING OF DEPARTMENT &3might display this line on a report:
BEGINNING OF DEPARTMENT 38
The following variables can also be used with DATE, TIME, and TIMESTAMP values in break heading text:
If a page in a report is wider than either the printer width or the default printing width specified in your PROFILE, QMF splits the page. It gives all parts of the split page the same page number, but with subscripts. (If you are using DBCS data and QMF splits the page, printing resumes on the second and subsequent pages of the report at the fourth byte position from the left side of the page.)
If you specify a break and you have a column-wrapped column with a usage code of FIRST, LAST, MIN, or MAX, you might need to increase the value in this field to see all the wrapped lines in the break summary. For information on column wrapping, see the CW entry in Edit Codes for Character Data.
The numbers you choose need not start with 1 or be consecutive.
For example, these values on FORM.BREAK1:
LINE ALIGN BREAK1 FOOTING TEXT ---- ----- ------------------- 3 LEFT DEPARTMENT &4 2 LEFT END OF LISTING
Display as:
END OF LISTING DEPARTMENT 35
For breaks with break summaries created with usage codes (except OMIT, BREAKn, GROUP, or ACROSS), QMF places the lines of break footing text anywhere from the left margin to the beginning of the indent area associated with the leftmost column of summary data.
The appended line of text must have the same LINE value as the line of text it is being appended to. If the report is not wide enough to accommodate the appended line of text, some of the text might be truncated.
For example, the following entries on FORM.BREAK1:
LINE ALIGN BREAK1 FOOTING TEXT ---- ------ ---------------------- 1 RIGHT TOTAL 1 APPEND SALARIES--DEPT. &4; 3 RIGHT 4 RIGHT 5 RIGHT
align columns as shown in the resulting report.
DEPT COMM JOB SALARY ------ ---------- ----- ---------- 66 55.50 CLERK 10988.00 - MGR 18555.50 844.00 SALES 16858.20 200.30 SALES 21000.00 811.50 SALES 18674.50 ---------- TOTAL SALARIES--DEPT. 66 86076.20 84 188.00 CLERK 13030.50 - MGR 19818.00 806.10 SALES 15454.50 1285.00 SALES 17844.00 ---------- TOTAL SALARIES--DEPT. 84 66147.00
If your installation supports DBCS data, see Names with double-byte characters.
By default, break footing text extends from the left margin of a report either to the beginning of the break summary data (if any), or to the right margin of a report. However, you can choose the width of break footing text on the Report text line width entry on FORM.OPTIONS (see pageFORM.OPTIONS).
To make the break footing text appear in a report in uppercase and lowercase, specify in your profile a CASE value of either STRING or MIXED.
Break footing text can contain the following variables:
For example, this break footing text:
END OF DEPARTMENT &3
Might display this line on a report:
END OF DEPARTMENT 38
For a description of &CALCid, see FORM.CALC.
For descriptions of &DATE, &TIME, and &PAGE, see page*** under BREAK1 HEADING TEXT.
For example, assume the fourth column of the report contains salaries and you want to summarize the salaries in each group in break footing text.
Write in the BREAK1 FOOTING TEXT:
TOTAL SALARY FOR DEPARTMENT &3 IS &SUM4
For example, the resulting line of break footing text in the report would be:
TOTAL SALARY FOR DEPARTMENT 38 IS $77,285.55
If you specify the aggregation variable in break footing text, you need not specify that same aggregation as the usage for that column. However, the aggregation must be compatible with the edit code and data type of the column. For example, you cannot specify &SUM3 in your final text if the data in column 3 has a character edit code.
If you use an aggregation variable with percent (PCT, TPCT, or TCPCT) in break footing text, and if you associate it with a column that has a D edit code, QMF formats the percent value as if it had an L edit code. Likewise, if you use the aggregation variable standard deviation and associate it with a column that has a P or a D edit code, QMF formats the standard deviation as if it had an L edit code.
For more information, see the L code under Edit Codes for Numeric Data and Variables Used in Forms.