Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I'm trying to perform a simple count aggregation based on 2 dimensions. Count Column is the expected output. I need count the orders for each cust_number and country combination and display the below output.
I tried using the below formula but it didn't help.
=SUM(AGGR(Count(Order_num),Cust_number,country))
| Cust_number | Country | Order_num | Count |
| 1000 | US | 111 | 3 |
| 1000 | US | 222 | 3 |
| 1000 | US | 333 | 3 |
| 1001 | US | 444 | 6 |
| 1001 | US | 555 | 6 |
| 1001 | US | 666 | 6 |
| 1001 | US | 777 | 6 |
| 1001 | US | 888 | 6 |
| 1001 | US | 999 | 6 |
then just use below
Dimensions
Cust_number
Country
MEasure
=count(Distinct Order_num)