Use FORM.MAIN to make simple changes to a report or chart.

Other panels (see the following table) work with FORM.MAIN to modify the appearance of reports or charts.

Table 1. Report/chart appearance change guide
Form name Function Additional information
FORM.MAIN Basic format of a report or chart FORM.MAIN
FORM.BREAKn (n = 1 to 6) Text before and after breaks in a report FORM.BREAKn
FORM.CALC Expressions for calculations in a report FORM.CALC
FORM.COLUMNS Use of columns in a report or chart FORM.COLUMNS
FORM.CONDITIONS Expressions for conditional formatting FORM.CONDITIONS
FORM.DETAIL Text included with column values or headings of a report FORM.DETAIL
FORM.FINAL Content and placement of final text in a report FORM.FINAL
FORM.OPTIONS Miscellaneous adjustments to a report FORM.OPTIONS
FORM.PAGE Content and placement of page headings and footings in a report or chart FORM.PAGE

Everything entered on FORM.MAIN is automatically reflected in a corresponding entry area on one of the other form panels. However, not all of the entry areas on the other panels are reflected on FORM.MAIN.

The previous table shows the entry areas on the FORM.MAIN panel. There are two areas on the FORM.MAIN and FORM.COLUMNS panels that are not entry areas: Total Width of Report Columns and NUM.
Figure 1. Entry areas on FORM.MAIN
 COLUMNS:               Total Width of Report Columns: 42                      
        A                                        B       C      D     E    F 
  NUM COLUMN HEADING                           USAGE   INDENT WIDTH EDIT  SEQ  
  --- ---------------------------------------- ------- ------ ----- ----- ---  
    1 ID                                               2      6     L     1    
    2 NAME                                             2      9     C     2    
    3 DEPT                                             2      6     L     3    
    4 JOB                                              2      5     C     4    
    5 YEARS                                            2      6     L     5    
 PAGE:    HEADING  ===>  G                                                        
          FOOTING  ===>                                                        
 FINAL:   TEXT     ===>  H                                                        
 BREAK1:  NEW PAGE FOR BREAK? ===> NO                                          
          FOOTING  ===>               I                                                        
 BREAK2:  NEW PAGE FOR BREAK? ===> NO                                          
          FOOTING  ===>                                                        
 OPTIONS: OUTLINE? ===> YES         J         DEFAULT BREAK TEXT? ===> YES        
 1=Help     2=Check    3=End          4=Show          5=Chart         6=Query  
 7=Backward 8=Forward  9=            10=Insert       11=Delete       12=Report 
 OK, cursor positioned.                                                        
 COMMAND ===>                                                  SCROLL ===> PAGE

Entry areas  A  through  F  correspond to identical entry areas on the FORM.COLUMNS panel. If all the columns in the form are not visible on the FORM.MAIN panel, you can scroll forward and backward to see them.

With these entry areas you can:
Assign column headings.

The DSQDC_COL_LABELS global variable controls whether the column heading defaults to the database label assigned to the column or the name of the column in the table from which it was selected.

Choose how to process columns.
Adjust indentation of columns.
Adjust width of columns.

The Default widths of data types table in FORM.COLUMNS shows the default width for each data type.

Specify formatting of columns. You can use certain edit codes in this field.
Change the sequence of columns.
The order of columns in the form is determined by the order in which they are specified in the SELECT statement of the query. Change the order of columns in the report by using the automatic reorder option or by changing the sequence (SEQ) column ( F ) on the FORM.MAIN panel.
Of these entry areas, COLUMN HEADING, USAGE, WIDTH, and EDIT apply to charts. The codes that appear in the USAGE entry area affect processing.
Entry areas  G  through  J  have corresponding form panels.
Enter one line of page heading and footing text for the report. QMF determines the horizontal and vertical placement of the heading and footing lines. The PAGE entry area corresponds to two entry areas on the FORM.PAGE panel.
Whatever appears in the PAGE entry area for a report heading also appears on a chart as its heading. Footing text cannot be specified for a chart.
Enter one line of final text for the report. The default placement of the line can be changed on the FORM.FINAL panel. The FINAL entry corresponds to one entry on the FORM.FINAL panel.
Enter footing text for up to two levels of breaks, and specify whether to start a new page each time the value in the specified break column changes. QMF determines the horizontal and vertical placement of the break footings. The BREAK1 and BREAK2 entry areas correspond to entry areas on the FORM.BREAK1 and the FORM.BREAK2 panels.
For reports with breaks, use the OUTLINE option to determine whether QMF displays the value of the break column on each tabular data line of the report. YES displays the value in the BREAK column only when the value itself changes.

For reports with breaks, use the DEFAULT BREAK TEXT option to determine whether to generate default break footing text to mark the BREAK aggregation line. When you do not enter any break footing text, YES displays a default break footing of asterisks.

This entry area corresponds to two entry areas on the FORM.OPTIONS panel.

Total width of report columns
This area shows the character width of the columns of the report.

You cannot change this area directly, but when you change INDENT, WIDTH, or edit codes for a column (or use a usage code of OMIT or ACROSS), the new total width of the report columns (in characters) appears after the colon.

If you use an edit code of G with DBCS data, each double-byte character counts as two positions.

If you use the usage code ACROSS, the width appears as an algebraic expression of the form: a + (N × b).
A constant value.
An unknown that stands for the number of sets of columns that are duplicated across the page, one set for each distinct value in the ACROSS column.
The width of each group of columns.
This area shows the number of each column in the order in which it was selected by the query that was run. You cannot change this area, but you can change the order of your columns by using the SEQ entry area.

You can indicate which column you want to use as a substitution variable by using its column number. For example, &6 refers to the sixth column selected by the query, even though it might not appear in the sixth position of the report.

Usually, columns appear on the report from left to right in order by their sequence numbers. However, when you use BREAK, GROUP, or an aggregation function on FORM.MAIN or FORM.COLUMNS and specify YES for Automatic reordering of report columns? on FORM.OPTIONS, QMF automatically reorders the columns in the report.

With automatic column reordering, if you use one or more of the BREAK codes as a usage, the control columns are moved to the left of the report. They appear there in order by their BREAK code numbers.

Also, columns whose usage is one of the aggregating usage codes (AVERAGE, COUNT, FIRST, LAST, CALCid, MAXIMUM, MINIMUM, STDEV, SUM, CPCT, CSUM, PCT, TPCT, or TCPCT) are moved to the right of the report and appear there in order by their column numbers.

The Report text line width column (Area C) and Automatic reordering of report column (Area J) in FORM.OPTIONS provides more information about width and order of columns.