你如何总结然后转置结果?
how do you summarize and then traspose the results?
这张图片显示了我需要实现的目标。我不知道该怎么做。
欢迎任何帮助。
也许:
=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))
这张图片显示了我需要实现的目标。我不知道该怎么做。 欢迎任何帮助。
也许:
=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))