Category:

Database related

Statistical (aggregate)

Conditional

Returns count of non-empty values in a dataset field among records which satisfy a certain condition.

Syntax

dataset_count_ex(
  StepNo Integer,
  GroupLevel Integer,
  FieldName String,
  Condition String
): Integer

Parameters

StepNo specifies the export step, in which the function must be calculated. It is used in HTML export context only; in other cases this parameter is ignored.

GroupLevel is reserved for future use and currently must be 0.

FieldName is the name of the field to calculate.

Condition is a boolean expression. But it must be written as a String constant (i.e. enclosed in single quotes) or a string deterministic expression.

Return value

Type: Integer.

Examples of using

dataset_count_ex(
  1, 
  0, 
  'LastPaymentDate', 
  'dataset_field_val(1, ''Age'') > 50'
)