Skrej
Board Regular
- Joined
- May 31, 2013
- Messages
- 176
- Office Version
- 365
- Platform
- Windows
Hi,
I have the following formula (previously provided via another thread) which cumulative lists instances of a code for a given number of sheets.
It works fine, and I understand how to modify it for given sheets. What I'd like to do is have it search for multiple codes (e.g. not just 't15' in the formula above, but also 't30, t45, t60 as well as 'e15', 'e30','e45' and 'e60'.
Is there I way I can set the value of d in the code above to include multiple options? I've tried adding the other codes separated by commas, but that throws an error.
(d="t15","t30)
(d="t15", d="t30")
Not sure if I'm just missing some syntax, or if I need to nest multiple index statement for each code, or what.
To further clarify, each month's sheet has a list of names down the leftmost column, followed by a code for each day (1 day per subsequent column to the right of the names). Other codes are used, but I don't need to tally them.
My main problem is I don't understand the formula well enough to interpret it.
I have the following formula (previously provided via another thread) which cumulative lists instances of a code for a given number of sheets.
Excel Formula:
=LET(d,VSTACK('Aug:Oct'!C8:V32),n,INDEX(d,,1),u,UNIQUE(FILTER(n,n<>"")),HSTACK(u,BYROW(u,LAMBDA(br,SUMPRODUCT((INDEX(d,,1)=br)*(d="t15"))))))
It works fine, and I understand how to modify it for given sheets. What I'd like to do is have it search for multiple codes (e.g. not just 't15' in the formula above, but also 't30, t45, t60 as well as 'e15', 'e30','e45' and 'e60'.
Is there I way I can set the value of d in the code above to include multiple options? I've tried adding the other codes separated by commas, but that throws an error.
(d="t15","t30)
(d="t15", d="t30")
Not sure if I'm just missing some syntax, or if I need to nest multiple index statement for each code, or what.
To further clarify, each month's sheet has a list of names down the leftmost column, followed by a code for each day (1 day per subsequent column to the right of the names). Other codes are used, but I don't need to tally them.
My main problem is I don't understand the formula well enough to interpret it.