Counts the number of unique values within a column or group for which all given conditions are true

Usage

CountDistinctIf(field, condition 1, ...)

field (required) The column of values to be counted. Duplicate and Null values are skipped.

condition 1(required) The condition to test. If the condition is true, then the row will be counted.Note: you can use operators in conditions.

condition 2+(optional) Additional conditions to test. If multiple conditions are given, they must all be True in order to be counted.

Example

CountDistinct([City], [Population] > 5000)
  • Finds the number of unique city names where the population is greater than 5000

 

See Also