Table:
0
A
B
C
D
E
F
G
1
invoice id
order id
payment method code
product id
order quantity
other item details
order item id
2
128
14
MasterCard
4
2
1
3
162
13
MasterCard
9
2
9
4
164
7
Visa
7
2
1
5
212
8
Visa
4
2
8
6
272
10
American E
3
2
5
7
398
3
American E
4
1
5
8
406
14
MasterCard
7
2
1
9
483
7
Visa
8
1
3
10
548
4
MasterCard
3
1
1
11
587
1
American E
4
2
1
12
612
6
American E
3
1
8
13
633
11
Visa
2
1
7
14
679
12
MasterCard
9
2
8
15
733
11
Visa
6
1
4
16
777
7
MasterCard
6
2
7

Questions and formulas:
Question: How many orders realised by each payment method?
Formula: SUMMARIZE(C1,SUMX(B1))
Formula2: SUMMARIZE(C2:C16,SUMX(B2:B16))
Level: easy
Question: Number of orders dealt by each payment.
Formula: SUMMARIZE(C1,SUMX(B1))
Formula2: SUMMARIZE(C2:C16,SUMX(B2:B16))
Level: easy
Question: Any invoice ids and payment method codes?
Formula: UNIQUE(HSTACK(C1,A1))
Formula2: UNIQUE(HSTACK(C2:C16,A2:A16))
Level: easy
Question: Payment method recorded on each invoice.
Formula: UNIQUE(HSTACK(C1,A1))
Formula2: UNIQUE(HSTACK(C2:C16,A2:A16))
Level: easy
Question: The number of orders per payment method.
Formula: SUMMARIZE(C1,SUMX(B1))
Formula2: SUMMARIZE(C2:C16,SUMX(B2:B16))
Level: easy
Question: How many orders dealt under each payment?
Formula: SUMMARIZE(C1,SUMX(B1))
Formula2: SUMMARIZE(C2:C16,SUMX(B2:B16))
Level: easy
Question: The payment method chosen by most orders
Formula: TAKE(SORT(SUMMARIZE(C1,SUMX(B1)), 2, -1), 1)
Formula2: TAKE(SORT(SUMMARIZE(C2:C16,SUMX(B2:B16)), 2, -1), 1)
Level: hard