Ashish Mathur
New Member
- Joined
- Mar 10, 2013
- Messages
- 40
- Office Version
- 365
- Platform
- Windows
Hi,
Assume this data is in range A1:M8. Months are in B1:M1 and products are in A2:A8. As you can see, products get repeated in A2:A8.
In cell A11, i enter this formula
=UNIQUE(A2:A8)
My objective is to get the monthwise total for each product. So, in cell B11, I enter this formula
=BYCOL($B$2:$M$8,LAMBDA(c,SUMIF($A$2:$A$8,A11,c)))
As expected, this spills column wise perfectly. However, I'd like it to spill row wise as well.
What modification would i need in cell B11 to make the formula spill row wise and column wise?
Thank you.
Assume this data is in range A1:M8. Months are in B1:M1 and products are in A2:A8. As you can see, products get repeated in A2:A8.
Product | Sep | Oct | Nov | Dec | Jan | Feb | Mar | Apr | May | Jun | Jul | Aug |
A | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 |
B | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
C | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 |
A | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 |
B | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 |
D | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 |
A | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 |
In cell A11, i enter this formula
=UNIQUE(A2:A8)
My objective is to get the monthwise total for each product. So, in cell B11, I enter this formula
=BYCOL($B$2:$M$8,LAMBDA(c,SUMIF($A$2:$A$8,A11,c)))
As expected, this spills column wise perfectly. However, I'd like it to spill row wise as well.
What modification would i need in cell B11 to make the formula spill row wise and column wise?
Thank you.