Forum Discussion
BYCOL & BYROW
Hi,
Below formula throwing #Calc error:
Need one array formula.
- =MAP(C3#&B4#,LAMBDA(A,COUNTA(UNIQUE(FILTER(K3:K25,(J3:J25&I3:I25=A))))))
This is the perfect solution by
Julian Poeltl
https://www.linkedin.com/in/julian-p%C3%B6ltl/
- OliverScheurichGold Contributor
=MAKEARRAY(5,4,LAMBDA(r,c,COUNTA(UNIQUE(FILTER(K3:K25,(I3:I25=INDEX(B4:B8,r))*(J3:J25=INDEX(C3:F3,c)))))))
Try the MAKEARRAY formula which returns the intended result in my file.
- anshul_mareleCopper Contributor
Very thanks OliverScheurich
But why to complicate a simple logic, if it is possible in Google Sheets then would also possible in Excel.So far Excel doesn't support nested arrays natively. Google Sheets supports.
As a comment, you use formula like IFERROR( COUNTA( UNIQUE(...
If UNIQUE returns an error, COUNTA gives 1. It counts all values, includes errors. Thus IFERROR never works here.
As variant that could be IFERROR( ROWS( UNIQUE(... which with gives 0 in case of error.