Search…
Resources
Related Links
count (aka cnt)
To return the number of items in an array or a selection of records
With this function, you can count the number of entries in arrays or tables. In combination with select ... where you can count records that meet a specific condition. For example how many entries have the status "open", or how many last names start with a "B".
The function can also be very helpful to find out if there are any duplicates in your table.

Syntax

count([any])
cnt([any])

Return

number

Examples

count("A", "B", "C")
Result: 3
count(select Invoices where Total >= 1000)
Result: 98 (if the table Invoices contains 98 records, where the Total is greater than USD1,000)
let ids := (select Contact).'Customer-Id';
cnt(ids) = cnt(unique(ids))
Return: If all IDs are unique, the result is Yes (true). If there are duplicates, the result is No (false).

See also

select ... where (coming soon)
Export as PDF
Copy link