GROUPCOUNT
Syntax
GROUPCOUNT()
Description
Counts the records in one group. No calculations are performed with this function.Â
Empty or <null> records of a group are calculated into GROUPCOUNT().
The GROUPCOUNT function results in an error only if the grouping itself contains an error.Â
This is an aggregate function.Â
Example
Given the following data:
Customer_ | Name | Item |
---|---|---|
2535 | Jon | Zamioculcas |
2888 | Mike | Spider Lily |
2535 | Jon | Datura |
2535 | Jon | Dahlia |
8654 | Windflower | |
5788 | Jon | Snapdragon |
2888 | Mike | Marguerite |
2535 | Jon | Windflower |
2888 | Mike | Elephant's Ear |
2535 | Jon | Chinese Evergreen |
5788 | Jon | Begonia |
5788 | Jon | Starfish Plant |
2535 | Jon | Hare's Foot Fern |
2535 | Jon | Venus Flytrap |
3545 | Monique | Red Flame Ivy |
8654 | Starfish Plant | |
4587 | Begonia | |
1234 | <error> | Elephant's Ear |
4321 | <error> | Snapdragon |
First create a group using GROUPBY(#RawData!Name)
Name |
---|
<error> |
Jon |
Mike |
Monique |
Use GROUPCOUNT() to return the amount of times a given argument appears, in relation to the GROUPBY() column.
Name | |
---|---|
<error> | <error> |
3 | |
Jon | 10 |
Mike | 3 |
Monique | 1 |