groupup
PERIOD

The groupup statement divides the database into groups, with a summary record at the end of each group. The groups are arranged in ascending order (low to high).


Parameters

This statement has one parameter:

period – identifies the span of each group. This parameter is optional, and only applies if the current field is a date field (it will be ignored for any other type of group). The options for this parameter are listed below. Use the options exactly as shown, with no quotes.

If the current field is a date field and this parameter is omitted, the database will be grouped by day.


Description

This statement divides the database into groups according to the current field. For example if the current field contains company names there will be one group per company, if the current field contains zip codes there will be one group per zip code. If the current field contains dates it may be grouped by day, week, month, quarter or year.

This example calculates summaries for cities and states, then displays the summary information. The outlinelevel statement collapses the outline so that the raw data is hidden and only the subtotals are displayed.

field State
groupup
field City
groupup
field Amount
total
outlinelevel 1

This example calculates totals for each month.

field Date
groupup by month
field Debit
total

Grouping by Weeks

This example calculates totals for each week.

field Date
groupup by week
field Debit
total

When grouping by weeks, Panorama checks the system preferences to see what day is the first day of the week. This is usually Sunday in the United States, but it can be different in other parts of the world, and it can be changed in the System Preferences Language & Region panel.

The group statement will honor this preference setting, so if the first day of the week is set to Monday, Saturday, or some other day, that is the day that will be used when grouping by weeks.


See Also


History

VersionStatusNotes
10.0UpdatedCarried over from Panorama 6.0, but when grouping by weeks the system preferences for first day of the week are now honored.