10. Using Report-Writer : Report Setup and Format : Automatic Determination of Default Settings : How Default Column Formats Are Determined
 
Share this page                  
How Default Column Formats Are Determined
If you do not specify a .format statement for a column, Report-Writer determines the column's default format in a manner similar to that used for determining the default column position. Report-Writer uses the innermost reference to a format for a column, or to an aggregate for a column, as the default format for a column. If you do not specify any formats for a column, Report-Writer determines defaults from the data type of the column, as described in Default Formats in the chapter "Report-Writer Expressions and Formats."
The default format for a column is best used in situations where you specify the format in the reference to a column in the .detail formatting statements. Aggregates of that column are specified in the footers for some of the breaks. Report-Writer then correctly uses the format you specified in the .detail section for the aggregates.
However, the .format statement is often quite useful for specifying a series of columns that are given the same format. For a good illustration of the use of the .format statement for this purpose, see Population Example in the appendix "Report-Writer Report Examples."