10. Using Report-Writer : Report Setup and Format : Automatic Determination of Default Settings : How Default Column Positions Are Determined
Share this page                  
How Default Column Positions Are Determined
If you do not specify a .position statement for a column, Report-Writer determines the column's default position for use with the .tab, .right, .left, or .center statements from the analysis of report formatting statements. Report-Writer determines default column positions by the first print position it encounters that has been specified for the printing of a value in that column or for an aggregate of that column.
Reports are usually set up in such a way that the innermost printing of column values occurs in the .detail statements of the report. Items such as column headers and aggregates, which print in the header or footer text for a break, can then use the .tab or another positioning statement in relation to the default position for the innermost position of a column. If you want to change the position of a column and its associated heading and/or aggregates, you must change the innermost print position for the column. Because all references to headers and aggregates are given in relative terms, Report-Writer changes their positions automatically.
As an example, see Account Example in the appendix "Report-Writer Report Examples." The default position for the amt column is determined by the cumulative aggregate for amt.