Power Fx function
CountRows — Power Fx function reference
Count rows in a table.
Syntax
powerfx
CountRows( Table )
Examples
powerfx
CountRows(Filter(Tasks, !Done))
→ A number
powerfx
CountRows(colCart) & " items in cart"
powerfx
If(CountRows(Filter(Tasks, Status = "Open")) = 0, "All caught up!")
Common mistakes & gotchas
- Not delegable — counts only the rows already retrieved.
- CountRows shows no delegation warning itself, but if it wraps a non-delegable Filter, the count only reflects the rows retrieved locally (often capped around 500–2000), not the true total.
- For an accurate count on a large table, prefer a delegable CountIf rather than CountRows(Filter(...)).
Related Power Fx functions
From Filtering, search & sort