COUNTIF, XCOUNTIF
Formula Explanation
countif: Filters the rows of data that meet the given criteria and performs a count operation on the specified column.
xcountif: Achieves incremental updates when the index column is not a formula, replaces the countif function, and can trigger automation.
Formula Syntax
Enter in the result column: countif(range of the column to be counted, condition)
- Range of the column to be counted: The column index of the data to be counted, such as AA1, AD12;
- Condition: Filters the values of the column to be counted, such as AA1>90, AH3=AI1 and AC1=AD3.
- Calculation can be performed within the same table or across multiple tables.
Usage Example
- This operation: Count the values in column CC2 of the CC table where the condition CC2="apple" is met, and write the count result into column CC3.
CC3 = countif(CC2, CC2="apple")
- Cross-table operation: Count the occurrences of CC2="apple" in the CC table, and write the count result into column CD2 of the CD table.
CD2 = countif(CC2, CC2 = CD1)