答案 0 :(得分:1)
也许:
=ARRAYFORMULA(QUERY(SPLIT(FLATTEN(IF(B2:D="",,A2:A&"♀"&B1:D1&"♀"&B2:D)), "♀"),
"where Col2 is not null", 0))
或者也许:
=ARRAYFORMULA(QUERY(SPLIT(FLATTEN(IF(B2:D="",,A2:A&"♀"&B1:D1&"♀"&B2:D)), "♀"),
"select Col1,Col2,sum(Col3)
where Col2 is not null
group by Col1,Col2
order by Col1,Col2,sum(Col3)
label sum(Col3)''", 0))