Count

The Count function counts the number of rows in a column.

Count (numbers, break_col, break_value)

where:

numbers references the column that contains the numbers on which the count is calculated.

break_col is an optional parameter that references a break column.

break_value is an optional parameter that returns the count of numbers column where value in break_col equals break_value.

Note:

If constant values in the break_value column are substituted for data items, dates and text strings must be enclosed in single quotes.

The following examples show the results of inserting the Count function in three separate tables.

Example 1

In this example, the Count function is used on the numeric column. The results are shown in the Computed column.

Count (Amount)

Table 151. Count Example

State

City

Amount

Computed

AZ

Tucson

112

9

CA

Burbank

240

9

CA

Glendale

97

9

FL

Palmetto

70

9

MD

Laurel

97

9

MI

Detroit

208

9

MN

Eagan

159

9

NY

New York

490

9

NY

Rochester

180

9