Skip to content

=INSTANCECOUNT

The =INSTANCECOUNT function returns the number of records in a process table that match a specified query. Useful for counting related entries, validating data, and conditional workflow logic.

=INSTANCECOUNT(TableID; TableQuery)
  • TableID – The unique identifier of the process table to query.

  • TableQuery – The query used to filter records in the table (e.g., [eq]Value).

  • Evaluates all records in the specified table that match the query.

  • Returns a numeric count of matching instances.

  • Supports dynamic queries using field tokens or fixed values.

  • Table queries must follow the correct query syntax (e.g., [eq], [neq]).

  • Field tokens in the query are filled in when the formula runs. If a filled-in value would leave part of the query with nothing to match on (for example, the field is blank, or its value starts with a semicolon), or if it contains [or] or the word OR with spaces around it, the function returns nothing instead of a count that includes records you didn’t ask for. A field holding several values separated by semicolons is counted by its first value. A date range with nothing on either side, such as [range].. after two empty date fields are filled in, matches no records, and so does a range the query can’t read.

  • Formula functions are case sensitive and must be written in ALL CAPS.

=INSTANCECOUNT(123456789012345678; tf_id_123456789012345678_if_text[eq]TestValue)

Returns: 6 (Assuming there are six entries in the table that match the query.)


INSTANCECOUNT, count records, table query, record counting, workflow formulas, process table evaluation, matching entries, numeric function, formula function