Skip to content

Automatic translation — the Portuguese version is the reference. View in Portuguese

CONT

On this page (10)

Counts rows (or non-blank values in the column).

FieldValue
CategoryStatistics
TypeAggregation (operates on a set of rows)
Arity0 to 1 arguments
Compiles to SQL (calculated column)Yes
VersionFormula engine v3.

Aliases#

Canonical name: CONT. Accepted aliases (case-insensitive): count.

Syntax#

code
CONT([coluna])

The 1st argument is the name of a column (bare identifier); the others are expressions.

Returns#

Number (count of rows or of non-blank values).

Null handling#

CONT() counts all rows; CONT(column) counts only non-blank values (blank doesn't count).

Evaluation context#

Aggregation — goes through the rows of the visual's current group.

Differences from DAX#

  • DAX equivalent: COUNT / COUNTROWS
  • Compatibility: DIFFERS from DAX — different semantics, watch out
  • Note: CONT() with no argument counts ROWS (like COUNTROWS); CONT(column) counts non-blank values of ANY type (like COUNTA) — DAX COUNT counts only numbers.

Examples#

code
CONT()

Example with values#

Input: 3 rows in the group.

code
CONT()  →  3

Expected result: 3

Business example#

Summarize a period — total revenue, average ticket, spread of the value per order.

Common errors#

Typos in a column name, an incompatible type, or an invalid argument become a friendly message (pt-BR) — the engine never silently returns a wrong number.


← Back to the formula index

Related links