There are situations in which you want to segment your data into groups, and then work on each group, instead of the whole data.
An example is when you want to know how many orders have been placed in each city, instead of the total number of orders placed.
To segment your data into groups, click on the column for which you want to create the groups, and choose 'Group by <column name>'.
You can then apply filters, sort, or use aggregate functions for each group.
To find the number of Orders for customer:
After using a Group By, only those fields will be part of the output of the aggregate by which you grouped. If you afterwards use an Aggregate Function, the development environment will add the aggregated column to the output. The rest of the fields will be still visible in the aggregate, but you won’t be able to reference them when using the aggregate results.
After grouping data, you can narrow down the result by filtering out groups with lower importance.
To do this:
To narrow down the list of the above example to the returning customers only, follow these steps:
Create a Calculated Column | Aggregate a Column into a Single Value